-
Notifications
You must be signed in to change notification settings - Fork 0
/
pg-example2.txt
48 lines (46 loc) · 1.24 KB
/
pg-example2.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
❯ npm run pg-intersecting-data-demo
> [email protected] pg-intersecting-data-demo
> ./run-pg.sh intersecting-data-demo
testing with READ COMMITTED
transaction successfully committed! totaled 1 and inserted total into 2
transaction successfully committed! totaled 2 and inserted total into 1
result of 1 transaction
fulfilled
result of 2 transaction
fulfilled
final values
class = 1, value = 10
class = 1, value = 20
class = 2, value = 100
class = 2, value = 200
class = 2, value = 30
class = 1, value = 330
testing with REPEATABLE READ
transaction successfully committed! totaled 1 and inserted total into 2
transaction successfully committed! totaled 2 and inserted total into 1
result of 1 transaction
fulfilled
result of 2 transaction
fulfilled
final values
class = 1, value = 10
class = 1, value = 20
class = 2, value = 100
class = 2, value = 200
class = 2, value = 30
class = 1, value = 300
testing with SERIALIZABLE
transaction successfully committed! totaled 1 and inserted total into 2
SequelizeDatabaseError
40001
rolling back failed transaction...
result of 1 transaction
fulfilled
result of 2 transaction
rejected
final values
class = 1, value = 10
class = 1, value = 20
class = 2, value = 100
class = 2, value = 200
class = 2, value = 30