Debian Codegraph @

src/test/isolation/expected/read-write-unique.out

raw
1 Parsed test spec with 2 sessions
2
3 starting permutation: r1 r2 w1 w2 c1 c2
4 step r1: SELECT * FROM test;
5 i
6 -
7 (0 rows)
8
9 step r2: SELECT * FROM test;
10 i
11 -
12 (0 rows)
13
14 step w1: INSERT INTO test VALUES (42);
15 step w2: INSERT INTO test VALUES (42); <waiting ...>
16 step c1: COMMIT;
17 step w2: <... completed>
18 ERROR: could not serialize access due to read/write dependencies among transactions
19 step c2: COMMIT;
20
21 starting permutation: r1 w1 c1 r2 w2 c2
22 step r1: SELECT * FROM test;
23 i
24 -
25 (0 rows)
26
27 step w1: INSERT INTO test VALUES (42);
28 step c1: COMMIT;
29 step r2: SELECT * FROM test;
30 i
31 --
32 42
33 (1 row)
34
35 step w2: INSERT INTO test VALUES (42);
36 ERROR: duplicate key value violates unique constraint "test_pkey"
37 step c2: COMMIT;