mirror of
https://github.com/MariaDB/server.git
synced 2025-02-01 19:41:47 +01:00
60d4662496
Non-transactional updates that take place inside a transaction present problems for logging because they are visible to other clients before the transaction is committed, and they are not rolled back even if the transaction is rolled back. It is not always possible to log correctly in statement format when both transactional and non-transactional tables are used in the same transaction. In the current patch, we ensure that such scenario is completely safe under the ROW and MIXED modes.
29 lines
742 B
Text
29 lines
742 B
Text
source include/have_binlog_format_mixed_or_statement.inc;
|
|
source include/have_debug.inc;
|
|
source include/master-slave.inc;
|
|
|
|
# We do this little stunt to make sure that the slave has started
|
|
# before we stop it again.
|
|
connection master;
|
|
CREATE TABLE t1 (a INT, b INT);
|
|
INSERT INTO t1 VALUES (1,10);
|
|
sync_slave_with_master;
|
|
source include/show_slave_status2.inc;
|
|
|
|
# Now we feed it a load data infile, which should make it stop with a
|
|
# fatal error.
|
|
connection master;
|
|
LOAD DATA INFILE '../../std_data/rpl_loaddata.dat' INTO TABLE t1;
|
|
|
|
connection slave;
|
|
wait_for_slave_to_stop;
|
|
source include/show_slave_status2.inc;
|
|
|
|
connection slave;
|
|
SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1;
|
|
START SLAVE;
|
|
|
|
connection master;
|
|
DROP TABLE t1;
|
|
sync_slave_with_master;
|
|
|