3 ms·
The key phrase is the line quoted is "default configuration". According to PostgreSQL docs, the default isolation level is "READ COMMITTED". Your example chec
by jrapdx3 12y ago
The key phrase is the line quoted is "default configuration". According to PostgreSQL docs, the default isolation level is "READ COMMITTED".
Your example check constraint indeed appears to work as advertised. Trying
UPDATE account SET balance = -1.00 where id = 1;
gives an ERROR message re:
new row for relation "account" violates check constraint ...
Still it's not clear exactly what the author sees re: where postgres fails. I'll have to read the article again. With any luck someone more knowledgeable than I am will shed light on the question.
- jasonwatkinspdx 12y agoIn short: prior to version 9.2, postgres's "serializable" level still allowed some transaction patterns that would be rejected by a strictly serial execution. Later versions prevent it. This paper: http://dl.acm.org/citation.cfm?id=1376690 http://dl.acm.org/citation.cfm?id=1376690 outlines the general issue. This paper discusses Postgres's solution: http://drkp.net/papers/ssi-vldb12.pdf http://drkp.net/papers/ssi-vldb12.pdf