Oracle 8i中回滚段使用和ORA-1555

http://tech.ddvip.com   2007年05月10日    社区交流

本文详细介绍Oracle 8i中回滚段使用和ORA-1555

  5. Read the Transaction Table using the Transaction ID. If the transaction has been committed and has a System Commit Number less than the querys System Change Number, update the status of the block (block cleanout) and start over at step 1.

  第5步细分

  ---IF 在Transaction Table 中根据Transaction ID 找到transaction

  -----------IF transaction 已经commit

  ----------------------IF query scn>commit scn

  ------------------------------------则接受该块,进行clean out,返回1

  ------------------------ELSEIF query scn

  -------------------------------------则进行一致性读,从第6步向后执行

  ------------ELSEIF transaction 没有commit

  ------------------------也进行一致性读,从第6步向后执行

  ---ELSEIF 在Transaction Table 中没有找到transaction(undo header中的transaction slot被覆盖了,也说明事务已经提交,因为只有提交后所在的transaction slot才能被覆盖。这样query scn则去比较control scn。在该回滚段上control scn以前的transaction都已经被提交,也就是事务表中所能找到的最小的commit scn了)

  ------------IF query scn

  -----------------------则无法知道query scn和commit scn得大小关系,出现ORA-01555错误

  ------------IF query scn>control scn

  -----------------------则query scn肯定>commit scn

  ------------------------------------则接受该块,进行clean out,并将block 中ITL标记上“U”,表示“upper bound commit” ,并返回1

责编:豆豆技术应用

正在加载评论...