Oracle automatically provides read consistency to a query so that all the data that the
query sees comes from a single point in time (statement-level read consistency).
Oracle can also provide read consistency to all of the queries in a transaction
(transaction-level read consistency).
Oracle uses the information maintained in its rollback segments to provide these
consistent views. The rollback segments contain the old values of data that have been
changed by uncommitted or recently committed transactions.
As a query enters the execution stage, the current system change number (SCN) is
determined. As data blocks are read on behalf of the query, only blocks written with the
observed SCN are used.Blocks with changed data (more recent SCNs) are reconstructed from
data in the rollback segments, and the reconstructed data is returned for the query.
Therefore,each query returns all committed data with respect to the SCN recorded at the
time that query execution began. Changes of other transactions that occur during a
query’s execution are not observed, guaranteeing that consistent data is returned for
1. Oracle 利用回滚段中的信息生成一个能保证一致性读的数据
2. 当查询进行执行阶段 , SCN是确定的 .
当查询进行扫描时 , 如果某个数据块内的数据被修改过 ,Oracle将使用回滚段中的信息重建此数据块
来自 “ ITPUB博客 ” ，链接：http://blog.itpub.net/10599713/viewspace-988772/，如需转载，请注明出处，否则将追究法律责任。