Understanding Phantom Reads in MySQL InnoDB
Phantom Reads in MySQL
Understanding the Problem
Consider a scenario using InnoDB with the default REPEATABLE READ isolation level:
CREATE TABLE `user_data` (
`id` int(11) NOT NULL,
`score` int(11) DEFAULT NULL,
`grade` int(11) DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `score` (`score`)
) ENGINE=InnoDB;
INSERT INTO user_data VALUES
(0,0 ...
Posted on Sun, 10 May 2026 07:15:14 +0000 by DangerousDave86