查询数据库重复数据

select * from new_doc_collection where title in (select title from new_doc_collection group by title having count(title) > 1)
and id in (select min(id) from new_doc_collection group by title having count(title)>1)

posted @ 2016-11-17 10:45  WangLC  阅读(150)  评论(0)    收藏  举报