Debian Codegraph @

mysql-test/suite/galera/t/galera_drop_multi.test

raw
1 #
2 # Test that multi-table DROP TABLE statements are properly replicated
3 # See http://dev.mysql.com/doc/relnotes/mysql/5.6/en/news-5-6-20.html
4 #
5
6 --source include/galera_cluster.inc
7 --source include/have_innodb.inc
8
9 CREATE TABLE t1 (f1 INTEGER) ENGINE=MyISAM;
10 CREATE TEMPORARY TABLE t2 (f1 INTEGER) ENGINE=MyISAM;
11 CREATE TABLE t3 (f1 INTEGER) ENGINE=InnoDB;
12 CREATE TEMPORARY TABLE t4 (f1 INTEGER) ENGINE=InnoDB;
13
14 CREATE TABLE t5 (f1 INTEGER);
15
16 SET AUTOCOMMIT=OFF;
17 START TRANSACTION;
18
19 DROP TABLE t1, t2, t3, t4;
20
21 INSERT INTO t5 VALUES (1);
22
23 COMMIT;
24
25 --connection node_2
26 --error ER_NO_SUCH_TABLE
27 SHOW CREATE TABLE t1;
28
29 --error ER_NO_SUCH_TABLE
30 SHOW CREATE TABLE t2;
31
32 --error ER_NO_SUCH_TABLE
33 SHOW CREATE TABLE t3;
34
35 --error ER_NO_SUCH_TABLE
36 SHOW CREATE TABLE t4;
37
38 CALL mtr.add_suppression("Slave SQL: Error 'Unknown table 'test\\.t2,test\\.t4'' on query\\. Default database: 'test'\\. Query: 'DROP TABLE t1, t2, t3, t4', Error_code: 1051");
39
40 --connection node_1
41 DROP TABLE t5;