3 ms·
It has race conditions. The only work-around that works (unless perhaps you have a 2-phase locking system, and are using serializable isolation level) involves
by petergeoghegan 11y ago
It has race conditions. The only work-around that works (unless perhaps you have a 2-phase locking system, and are using serializable isolation level) involves subtransactions.
For example: http://www.postgresql.org/docs/current/static/plpgsql-control-structures.html#PLPGSQL-UPSERT-EXAMPLE http://www.postgresql.org/docs/current/static/plpgsql-contro...
This is ugly an inefficient.
- deleted 11y ago[deleted]