Debian Codegraph @

mysql-test/suite/galera/r/galera_var_auto_inc_control_off.result

raw
1 connection node_2;
2 connection node_1;
3 connection node_1;
4 SET GLOBAL wsrep_auto_increment_control = OFF;
5 SET GLOBAL auto_increment_increment = 1;
6 SET GLOBAL auto_increment_offset = 1;
7 connection node_2;
8 SET GLOBAL wsrep_auto_increment_control = OFF;
9 SET GLOBAL auto_increment_increment = 1;
10 SET GLOBAL auto_increment_offset = 1;
11 connection node_1a;
12 SELECT @@auto_increment_increment = 1;
13 @@auto_increment_increment = 1
14 1
15 SELECT @@auto_increment_offset = 1;
16 @@auto_increment_offset = 1
17 1
18 CREATE TABLE t1 (f1 INTEGER AUTO_INCREMENT PRIMARY KEY, node VARCHAR(10)) ENGINE=InnoDB;
19 SHOW CREATE TABLE t1;
20 Table Create Table
21 t1 CREATE TABLE `t1` (
22 `f1` int(11) NOT NULL AUTO_INCREMENT,
23 `node` varchar(10) DEFAULT NULL,
24 PRIMARY KEY (`f1`)
25 ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_uca1400_ai_ci
26 connection node_2a;
27 SHOW CREATE TABLE t1;
28 Table Create Table
29 t1 CREATE TABLE `t1` (
30 `f1` int(11) NOT NULL AUTO_INCREMENT,
31 `node` varchar(10) DEFAULT NULL,
32 PRIMARY KEY (`f1`)
33 ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_uca1400_ai_ci
34 connection node_1a;
35 SELECT @@auto_increment_increment = 1;
36 @@auto_increment_increment = 1
37 1
38 SELECT @@auto_increment_offset = 1;
39 @@auto_increment_offset = 1
40 1
41 SET AUTOCOMMIT=OFF;
42 START TRANSACTION;
43 INSERT INTO t1 (node) VALUES ('node1');
44 SELECT f1 FROM t1;
45 f1
46 1
47 connection node_2a;
48 SELECT @@auto_increment_increment = 1;
49 @@auto_increment_increment = 1
50 1
51 SELECT @@auto_increment_offset = 1;
52 @@auto_increment_offset = 1
53 1
54 SET AUTOCOMMIT=OFF;
55 START TRANSACTION;
56 INSERT INTO t1 (node) VALUES ('node2');
57 SELECT f1 FROM t1;
58 f1
59 1
60 connection node_1a;
61 COMMIT;
62 connection node_2a;
63 COMMIT;
64 ERROR 40001: Deadlock found when trying to get lock; try restarting transaction
65 connection node_1a;
66 SELECT * FROM t1;
67 f1 node
68 1 node1
69 connection node_2a;
70 SELECT * FROM t1;
71 f1 node
72 1 node1
73 DROP TABLE t1;