Hi friends,
I want to know,what is the query to delete the duplicate rows from the table?
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Satyapriya NayakPosted Nov 13, 2011, 8:15 AM
STEP 1 - Insert your distinct data into a temporary table select distinct* into temp from TableName
STEP 2 - Delete From TableName
STEP 3 - Insert TableName Select * From temp
Thanks
Deepak DwijPosted Nov 15, 2011, 6:48 PM
Hemant KumarPosted Nov 13, 2011, 7:27 AM
http://blog.sqlauthority.com/2007/03/01/sql-server-delete-duplicate-records-rows/