CREATING A READ CONSISTENT VIEW STEPS
1. Read the Data Block. If the block is resident in memory, create a clone to perform the undo. 2. Read the Row Header. 3. Check the LockByte to determine if there is an ITL entry. 4. Read the ITL to determine the Transaction ID.
Automatic UNDO Internals
5. Read the Transaction Table. If the transaction has been committed and has a System Commit Number less than the query’s System Change Number, cleanout the block and move on the next data block (if required) and Step 1. 6. Read the last undo block indicated 7. Compare the block transaction id with the transaction table transaction id. If the Transaction ID in the undo block does not equal the Transaction ID from the Transaction Table, then signal an ORA-01555 “Snapshot Too Old.”. 8. Starting with the head undo entry, apply the changes to the block. 9. If the tail undo entry (the last one read) indicates another data block address, read the indicated undo block into memory. Repeat 7 & 8 until the first record does not contain a value for the data block address. 10. When there is no previous data block address, the transaction has been undone. 11. If the undo entry contains a) a pointer to a previous transaction undo block address, read the TxID in the previous transaction undo block header and read the appropriate Transaction Table entry. Return to step 5. b) an ITL record, restore the ITL record to the data block. Return to step 4.
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/19602/viewspace-1020837/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/19602/viewspace-1020837/