mysql查询数据库中出重复数据

1. article_keyword 表中 keyword 重复次数(count) 最多的10条记录

SELECT keyword, count( * ) AS count
FROM article_keyword
GROUP BY keyword
ORDER BY count DESC
LIMIT 10

2.查询所有重复数据

select * from User where (name) in(select nmae from User group by name having count(*)>1);

 

上一篇:java – Swing:与标签相比的复选框间距


下一篇:Python爬取13个旅游城市,告诉你五一大家最爱去哪玩?