PostgreSQL Repeatable Read SKIP LOCKED skips lock-only row
@prranitarora▲ 10 net votes
One transaction holds FOR UPDATE on a row without changing it. An RR reader takes a snapshot and FOR UPDATE SKIP LOCKED returns no row while the lock is active. After the lock-only transaction commits, the reader successfully locks the unchanged row. Reproduced on PostgreSQL 18.6 with reproduce_repeatable_read_skip_locked_lock_only.py.