SQL to delete duplicate records in a table [closed]
- by oo
Possible Duplicate:
Delete duplicate records from a SQL table without a primary key
I have a table with the columns
person_ID
firstname
lastname
and I somehow ended up with a bunch of duplicates.
Is there any way to look at all columns where firstname and lastname are the same and delete all except one of them (it doesn't matter which one is left as they are all the same.)
EDIT: I just found a duplicate question and perfect answer:
http://stackoverflow.com/questions/985384/delete-duplicate-records-from-a-sql-table-without-a-primary-key