Debian Codegraph @

mysql-test/suite/binlog_nogtid/t/binlog_mysqlbinlog_row_trans.test

raw
1 # mysqlbinlog_trans.test
2 #
3 # Show that mysqlbinlog work correctly with transactions.
4 #
5
6 --let $engine_type= InnoDB
7
8 --source include/have_binlog_format_row.inc
9
10 #
11 # The test case records the output of mysqlbinlog, thence if compression
12 # is enabled, then it fails as the compression event is output.
13 #
14 --source include/not_binlog_transaction_compression_on.inc
15
16 --source include/have_log_bin.inc
17
18 --echo #
19 --echo # Preparatory cleanup.
20 --echo #
21 --disable_warnings
22 DROP TABLE IF EXISTS t1;
23 --enable_warnings
24
25 --echo #
26 --echo # We need a fixed timestamp to avoid varying results.
27 --echo #
28 SET timestamp=1000000000;
29
30 --echo #
31 --echo # Delete all existing binary logs.
32 --echo #
33 RESET MASTER;
34
35 --echo #
36 --echo # Bug#22350047: IF CLIENT KILLED AFTER ROLLBACK TO SAVEPOINT PREVIOUS
37 --echo # STMTS COMMITTED
38 --echo #
39
40 connect(connection1, localhost, root,,);
41 --let $connection_id=`SELECT CONNECTION_ID()`
42
43 --eval CREATE TABLE t1(a INT) ENGINE=$engine_type
44 BEGIN;
45 INSERT INTO t1 VALUES(1);
46 SAVEPOINT tx_0;
47 ROLLBACK TO SAVEPOINT tx_0;
48
49 connection default;
50 --replace_result $connection_id CONN_ID
51 --eval KILL CONNECTION $connection_id
52
53 --echo # Without the patch, field 'a' contained the value 1
54 SELECT * FROM t1;
55 DROP TABLE t1;