Sql Server 查询重复记录

 

参考网址:http://database.51cto.com/art/201103/250046.htm

SQL Server数据库多种方式查找重复记录

select * from dbo.T0058_PointObjectGIS
where C0058_Lon in(select C0058_Lon from T0058_PointObjectGIS group by C0058_Lon having(COUNT(*))>1)

 

select c0130_entcode,c0130_entname,COUNT(*) from T0140_EntList group by c0130_entcode,c0130_entname

 

posted @ 2013-08-02 14:54  高山-景行  阅读(186)  评论(0编辑  收藏  举报