Debian Codegraph @

mysql-test/suite/rpl/r/rpl_idempotency.result

raw
1 include/master-slave.inc
2 [connection master]
3 call mtr.add_suppression("Slave SQL.*Can.t find record in .t[12].* error.* 1032");
4 call mtr.add_suppression("Slave SQL.*Cannot delete or update a parent row: a foreign key constraint fails .* error.* 1451");
5 call mtr.add_suppression("Slave SQL.*Cannot add or update a child row: a foreign key constraint fails .* error.* 1452");
6 call mtr.add_suppression("Slave SQL.*Could not execute Write_rows event on table test.* Duplicate entry .1. for key .PRIMARY.* error.* 1062");
7 call mtr.add_suppression("Can't find record in 't1'");
8 call mtr.add_suppression("Can't find record in 't2'");
9 connection master;
10 CREATE TABLE t1 (a INT PRIMARY KEY);
11 CREATE TABLE t2 (a INT);
12 INSERT INTO t1 VALUES (-1),(-2),(-3);
13 INSERT INTO t2 VALUES (-1),(-2),(-3);
14 connection slave;
15 SET @old_slave_exec_mode= @@global.slave_exec_mode;
16 SET @@global.slave_exec_mode= IDEMPOTENT;
17 connection slave;
18 DELETE FROM t1 WHERE a = -2;
19 DELETE FROM t2 WHERE a = -2;
20 connection master;
21 DELETE FROM t1 WHERE a = -2;
22 DELETE FROM t2 WHERE a = -2;
23 SELECT * FROM t1 ORDER BY a;
24 a
25 -3
26 -1
27 SELECT * FROM t2 ORDER BY a;
28 a
29 -3
30 -1
31 connection slave;
32 SELECT * FROM t1 ORDER BY a;
33 a
34 -3
35 -1
36 SELECT * FROM t2 ORDER BY a;
37 a
38 -3
39 -1
40 include/check_slave_no_error.inc
41 INSERT IGNORE INTO t1 VALUES (-2);
42 connection master;
43 INSERT IGNORE INTO t1 VALUES (-2);
44 SELECT * FROM t1 ORDER BY a;
45 a
46 -3
47 -2
48 -1
49 connection slave;
50 SELECT * FROM t1 ORDER BY a;
51 a
52 -3
53 -2
54 -1
55 include/check_slave_no_error.inc
56 connection slave;
57 UPDATE t1 SET a = 1 WHERE a = -1;
58 UPDATE t2 SET a = 1 WHERE a = -1;
59 connection master;
60 UPDATE t1 SET a = 1 WHERE a = -1;
61 UPDATE t2 SET a = 1 WHERE a = -1;
62 SELECT * FROM t1 ORDER BY a;
63 a
64 -3
65 -2
66 1
67 SELECT * FROM t2 ORDER BY a;
68 a
69 -3
70 1
71 connection slave;
72 SELECT * FROM t1 ORDER BY a;
73 a
74 -3
75 -2
76 1
77 SELECT * FROM t2 ORDER BY a;
78 a
79 -3
80 1
81 include/check_slave_no_error.inc
82 connection slave;
83 drop table t1, t2;
84 connection master;
85 DROP TABLE t1, t2;
86 connection slave;
87 include/check_slave_no_error.inc
88 create database d;
89 create database e;
90 connection master;
91 create database d;
92 create database if not exists e;
93 connection slave;
94 include/check_slave_no_error.inc
95 drop database d;
96 drop database e;
97 connection master;
98 drop database d;
99 drop database if exists e;
100 connection slave;
101 include/check_slave_no_error.inc
102 SET @@global.slave_exec_mode= @old_slave_exec_mode;
103 include/rpl_end.inc