Ch8 Sol1b: phantom, write skew, serializable

Ch8 Sol1b: phantom, write skew, serializable A sequence diagram generated by Archify. BEGIN: SELECT COUNT(*) FROM bookings -> 2 INSERT R:10-11; COMMIT recount -> 3: PHANTOM under READ COMMITTED RR: recount from snapshot -> 2, no phantom Alice: snapshot shows {Alice, Bob} on call Bob: snapshot shows {Alice, Bob} on call cover present: Alice goes off call; COMMIT Bob goes off call too: on-call EMPTY SERIALIZABLE re-run: Alice commits Bob: 40001 abort, retries whole txn retry: Alice gone, Bob stays on call Phantom: recount inside one transaction Write skew: the snapshot lies to both Serializable: exactly one committer Session A · reader / Alice · Sequence participant Session A reader / Alice Session B · inserter / Bob · Sequence participant Session B inserter / Bob PostgreSQL 18 · documented rules only · Sequence participant PostgreSQL 18 documented rules only Legend main request return security message