From: Peter C. <Pet...@me...> - 2006-06-14 11:35:02
|
> From: Matthew Buckett > If we updated to TRANSACTION_REPEATABLE_READ=20 > then we don't have to=20 > worry about a read row being modified under our feet. Sorry, doesn't work - you have to go to SERIALIZABLE on MSSQL at least. Otherwise: - A reads (acquires read lock); - B reads (acquires read lock); - A adds; - B adds; - A updates (tries to upgrade to write lock, waits on B's read lock); - B updates (tries up upgrade to write lock, system detects deadlock and rolls back one transaction). ... Causes problems at best, deadlock at worst, I think. - Peter |