【发布时间】:2011-11-23 07:17:52
【问题描述】:
我很困惑。我正在阅读有关 Oracle 中的 MVCC 的信息。我认为 MVCC 意味着没有锁。但是,我在其他地方读到所有UPDATEs 都会自动锁定,无论隔离级别如何。有人可以解释在 Oracle 更新期间会发生什么吗?当多个读提交事务尝试并发update t set c = c + 1 where id = 3 时会发生什么。结果是什么,在任一事务之前给定 c = 1,锁和 SCN 发生了什么?
Begin T1
Begin T2
T1: update t set c = c + 1 where id = 3
T2: update t set c = c + 1 where id = 3
Commit T1
Commit T2
【问题讨论】:
标签: database oracle concurrency transactions