summaryrefslogtreecommitdiff
path: root/mysql-test/suite/innodb/r/xa_recovery.result
blob: ed9f19b7eb318a2b816e12bb80bff5ca57ac2205 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
CREATE TABLE t1 (a INT) ENGINE=InnoDB;
INSERT INTO t1 VALUES (1);
connect  con1,localhost,root;
XA START 'x';
UPDATE t1 set a=2;
XA END 'x';
XA PREPARE 'x';
connect  con2,localhost,root;
CREATE TABLE t2 (a INT) ENGINE=InnoDB;
XA START 'y';
INSERT INTO t2 VALUES (1);
XA END 'y';
XA PREPARE 'y';
connection default;
# restart: --innodb-force-recovery=2
disconnect con1;
disconnect con2;
connect  con1,localhost,root;
SELECT * FROM t1 LOCK IN SHARE MODE;
connection default;
DROP TABLE t2;
# restart
disconnect con1;
SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED;
SELECT * FROM t1;
a
2
XA ROLLBACK 'x';
SELECT * FROM t1;
a
1
DROP TABLE t1;
SET GLOBAL innodb_fast_shutdown=0;
# restart
XA ROLLBACK 'y';