Concurrency
read-write-conflicts
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: