1 include/master-slave.inc
3 create table t1 (a int);
4 insert into t1 values (10);
5 create table t2 (a int);
6 create table t3 (a int) engine=merge union(t1);
7 create table t4 (a int);
8 insert into t4 select * from t3;
9 rename table t1 to t5, t2 to t1;
10 flush no_write_to_binlog tables;
11 show binlog events from <binlog_start>;
12 Log_name Pos Event_type Server_id End_log_pos Info
13 master-bin.000001 # Query # # use `test`; rename table t1 to t5, t2 to t1
20 include/wait_for_slave_to_stop.inc
22 flush tables with read lock;
24 include/wait_for_slave_to_start.inc
26 ERROR HY000: Can't execute the given command because you have active locked tables or an active transaction
28 drop table t3, t4, t5;