MySQL Forums
Forum List  »  Memory Storage Engine

Re: Thread Safe
Posted by: Ingo Strüwing
Date: September 12, 2005 03:22AM

Yes and yes if there is only one row.

The table gets locked for every update statement. Then for every row in the table count is incremented if it is < 5000. Then the lock is realeased. The next thread gets the lock, increments count for every row with count < 5000 and unlocks the table again. Then the next thread gets the lock and so forth.

If you have only one row in the table, starting with count 0, 5000 update statements will affect one row and then no row will be affected any more.

Options: ReplyQuote

Written By
September 09, 2005 04:29AM
Re: Thread Safe
September 12, 2005 03:22AM

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.