Click here to Skip to main content
15,888,521 members
Articles / Database Development / SQL Server / SQL Server 2008

How to remove duplicate rows in SQL Server 2008 when no key is present

Rate me:
Please Sign up or sign in to vote.
0.00/5 (No votes)
2 Sep 2011CPOL 15K   1  
Find out the number of duplicates in the table:select count(*), VISTX_ST_FIPS,VISTX_CTY_FIPS,VISTX_TC from TR00.NV_STARTER_INDEXgroup by VISTX_ST_FIPS,VISTX_CTY_FIPS,VISTX_TC having count(*)>1--- Delele them using following statementDELETEFROM TR00.NV_STARTER_INDEXWHERE...

Views

Daily Counts

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
United States United States
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions