SQL for deleting duplicate records.