DB2 has 4 isolation levels. All 4 have advantages and disadvantages. Explained in detail about each isolation level.
The Purpose of DB2 Four Isolation Levels
- CS- Cursor stability-Page level lock. After every page reads it releases locks to a page for reading. The disadvantage is when the whole table reads during commit time may not match for first reading and second reading.
- RR-Repeatable Read: Page-level locking-It holds till commit occurs. The report received before and after would be the same.
- UR- uncommitted read. Allows an application to read while acquiring few locks, at the risk of reading uncommitted data
- RS- Read stability: Read stability option enables an application to read the same pages or rows more than once and prevents updates or deletes to qualifying rows by other processes. However, other applications can insert or update rows that did not satisfy the search condition of the original application.