![]() ![]() No row can change, nor deleted, nor new rows could be inserted by a concurrent transaction. under SERIALIZABLE reads the second select is guaranteed to see exactly the same rows as the first.New rows may be added by a concurrent transaction in that one minute, but the existing rows cannot be deleted nor changed. under REPEATABLE READ the second SELECT is guaranteed to display at least the rows that were returned from the first SELECT unchanged.The second select will always see the new data. A concurrent transaction may update the record, delete it, insert new records. under READ COMMITTED, the second SELECT may return any data. ![]() That is a simple task that issue two reads from table T, with a delay of 1 minute between them. And consider you have a simple task like the following: BEGIN TRANSACTION Say you have a table T with a column C with one row in it, say it has the value '1'. The next isolation level, serializable, makes an even stronger guarantee: in addition to everything repeatable read guarantees, it also guarantees that no new data can be seen by a subsequent read. Repeatable read is a higher isolation level, that in addition to the guarantees of the read committed level, it also guarantees that any data read cannot change, if the transaction reads the same data again, it will find the previously read data in place, unchanged, and available to read. It makes no promise whatsoever that if the transaction re-issues the read, will find the Same data, data is free to change after it was read. It simply restricts the reader from seeing any intermediate, uncommitted, 'dirty' read. Read committed is an isolation level that guarantees that any data read was committed at the moment is read. ![]()
0 Comments
Leave a Reply. |