MySQL Forums
Forum List  »  Performance

Re: UPDATE 6m records quickly
Posted by: James Day
Date: January 24, 2005 01:04AM

You might try to do the updates in chunks which match the physical order of the records (order added for MyISAM unless you've done an ALTER TABLE .. ORDER BY, primary key for InnoDB). Working in chunks by physical order the select will get the data quickly with few sequential reads and the update will update it while it's still cached from the select. Otherwise you'd need to hold all the affected records in cache and that can be a challenge compared to a chunk size you can choose so that it always fits.

Options: ReplyQuote


Subject
Views
Written By
Posted
3267
January 23, 2005 03:47PM
Re: UPDATE 6m records quickly
1940
January 24, 2005 01:04AM
2109
January 24, 2005 03:51PM
1943
January 24, 2005 03:53PM
2043
January 24, 2005 09:43PM
1930
January 25, 2005 12:47AM
1863
January 25, 2005 02:41PM
1893
January 25, 2005 11:32PM
1969
January 26, 2005 03:41AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.