db.l3.ai

Play

lessons

what-changed-in-19

editor

engine: not started

results

Run a query to see rows here.

check

Isolation replay

Two sessions that read a balance and then write it can overwrite each other (a lost update). Lock the row first.

task

After the recorded lost-update replay, take 30 off account 1 safely: lock the row first with FOR UPDATE, in one transaction.

hints