Frontier Software

Concurrency

Concurrency Control

read-write-conflicts

Understanding locks

7 tips for dealing with locks

Something I learnt the hard way by getting the computer to play games over-and-over and then update the average scores each time was it crashed my Postgresql functions with

ERROR:  relation "_states" does not exist
LINE 1: SELECT id FROM _states WHERE state = NULL

The problem was garbage values were getting returned from queries if their table was being updated, and the solution was: