例如表名为Course
需要查询出name重复的有那些???
解答如下:
补充:
如:查询每个姓名出现大于2次,SQL如下
SELECT COUNT(NAME) as '出现次数', NAME FROM 表名GROUP BY NAME HAVING count(NAME) > 2 ORDER BY 出现次数 DESC
posted on 2017-02-20 17:39 王月波 阅读(19075) 评论(0) 编辑 收藏 举报