sql 建立索引之前计算区分度

select cutomer_id,title,content from product_comment where audit_status=1 and product_id=1 and product_id=199726 limit 0,5

 

select count(DISTINCT audit_status)/COUNT(*) AS audit_rate COUNT(DISTINCT product_id)/COUNT(*) AS product_rate FROM product_comment

 

posted @ 2019-03-24 20:22  南望孤笑  阅读(583)  评论(0编辑  收藏  举报