refactoringself.com
SQL Server – Deleting Duplicate Rows
Oh what a tangled web we weave when we don’t use unique constraints or primary keys… Using some clever rules about deleting from a view (also applies to a common table expression). You…