标签:rom 商品 sel 大于 select _id name having 字段
SELECT COUNT( 要统计次数的字段) FROM 表 GROUP BY 要统计字段 HAVING COUNT(要统计字段) > num
查询下单次数超过50次商品
SELECT goods_id, goods_name,COUNT(goods_id) FROM tp_order_goods GROUP BY goods_id HAVING COUNT(goods_id) > 50
标签:rom 商品 sel 大于 select _id name having 字段
原文地址:http://www.cnblogs.com/donaldworld/p/6403537.html