From http://stackoverflow.com/questions/1651999/mysql-remove-duplicates-from-big-database-quick