I have a table with 2 col. One is the self-inc PK, which I want to keep, 2nd is varchar (string). What's the query like for removing rows that have duplicate string in 2nd column.
I saw something like this on some web site but not sure if this is correct
delete from Table
where ID in
(SELECT MAX(ID) FROM TABLE WHERE NAME IN (SELECT NAME FROM TABLE
GROUP BY NAME