Click here to Skip to main content
15,892,298 members
Articles / Database Development / SQL Server

To find duplicate rows in table

Rate me:
Please Sign up or sign in to vote.
4.50/5 (2 votes)
1 Feb 2012CPOL 11.2K  
Here is an alternative way to find duplicates in a table by making use of over clause http://msdn.microsoft.com/en-us/library/ms189461.aspx[^];with duplicates as (SELECT rowno=row_number() over (partition by colname order by colname), colname, colname from TableName)select * from...

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
South Africa South Africa
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions