1 select * from tablename as A where (select count(*) from tablename where name = A.name) > 1
2 select name from tablename group by name,id having count(*)>=2
Powered By PJBlog3 v3.1.6.227 CopyRight 2005 - 2008, 扬帆blog关注delphi_asp_php_div+css_seo xhtml | css
鲁ICP备09063801号