4 ms·
Database isolation levels is a multi-threaded problem, you have to apply the same semantics to your database as you would your code. If you don't want "phantom
by jabart 3y ago
Database isolation levels is a multi-threaded problem, you have to apply the same semantics to your database as you would your code. If you don't want "phantom reads", then lock the whole table, which is bad. So maybe don't do that and grab a copy when your transaction starts instead. It's not broken, it's not common knowledge and should be. It's why we had DBAs force everything to stored procedures because the DBAs were the abstraction layer and high level experts who knew all these details.