0
Delete duplicate records from database
Posted by Rajendra Prasad Panchati
on
Monday, February 08, 2010
in
SQL Server
I and with the help of my friend, discovered a simple method to delete duplicate set(s) of records from a table in your database.
SELECT DISTINCT * INTO Temp_Table FROM Your_Table
DROP TABLE Your_Table
SELECT * INTO Your_Table FROM Temp_Table
DROP TABLE Temp_Table
SELECT DISTINCT * INTO Temp_Table FROM Your_Table
DROP TABLE Your_Table
SELECT * INTO Your_Table FROM Temp_Table
DROP TABLE Temp_Table
More
Less