blob: d341a1816e5d83e6fd92aaa3594e48000b65f73a (
plain)
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
|
connection node_2;
connection node_1;
connection node_1;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
COMMIT;
connection node_2;
CREATE TABLE sum_table (f1 INTEGER);
SELECT SUM(f1) = 100 FROM sum_table;
SUM(f1) = 100
1
connection node_1;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
connection node_2;
SET AUTOCOMMIT=OFF;
START TRANSACTION;
UPDATE t100 SET f1 = 3;
connection node_1;
COMMIT;
connection node_2;
COMMIT;
ERROR 40001: Deadlock found when trying to get lock; try restarting transaction
DROP SCHEMA test;
CREATE SCHEMA test;
|