Home > database > How to understand the mysql dirty read
How to understand the mysql dirty read
Time:09-16
Dirty read: a transaction read another transaction uncommitted data, Have some questions want to ask next: 1. DML operation are all the data in innodb_buffer_pool data in the cache, the check point to check when the data is written to disk? 2. If the transaction in the statement has been executed, but the transaction has not yet been submitted, the data in the database has been changed, the transaction commit specific have what effect? 3. Select read data (i.e., the "data in the database") refers to the innodb_buffer_pool cached data or the data in the disk, according to the isolation level to distinguish?
Understand it if you have any questions? Read uncommitted level, select the innodb_buffer_pool cache read data inside, so any transaction may read uncommitted data, dirty reads, Reading level has been submitted, select use snapshot read (the snapshot read), so can only read other transactions have been submitted data in the disk + transaction itself changes but not submitted data, avoid the dirty reads,