* Ville Mattila > I was wondering how would it be possible to delete those records from > database which has just same data? There can be also up to ten > copies of the record in database, and all but one should be deleted. > Do you have any easy way to do this?
You could do it by creating a new table, fill it with DISTINCT values from the old table, drop the old table, and then rename the new table to the old name: create table new_table select distinct * from old_table; drop table old_table; alter table new_table rename old_table; You would also need to add any indexes to the new table. -- Roger --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php