summaryrefslogtreecommitdiff
path: root/storage/tokudb/mysql-test/tokudb/r/tokudb_support_xa.result
blob: c265f38cdc249711f80057d8e2960277aac94d65 (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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
'#--------------------begin------------------------#'
SET @session_start_value = @@session.tokudb_support_xa;
SELECT @session_start_value;
@session_start_value
1
SET @global_start_value = @@global.tokudb_support_xa;
SELECT @global_start_value;
@global_start_value
1
SET @@session.tokudb_support_xa = 0;
SET @@session.tokudb_support_xa = DEFAULT;
SELECT @@session.tokudb_support_xa;
@@session.tokudb_support_xa
1
SET @@global.tokudb_support_xa = 0;
SET @@global.tokudb_support_xa = DEFAULT;
SELECT @@global.tokudb_support_xa;
@@global.tokudb_support_xa
1
'#--------------------case#1 valid set support_xa------------------------#'
SET @@session.tokudb_support_xa = 0;
SELECT @@session.tokudb_support_xa;
@@session.tokudb_support_xa
0
SET @@session.tokudb_support_xa = 1;
SELECT @@session.tokudb_support_xa;
@@session.tokudb_support_xa
1
SET @@global.tokudb_support_xa = 0;
SELECT @@global.tokudb_support_xa;
@@global.tokudb_support_xa
0
SET @@global.tokudb_support_xa = 1;
SELECT @@global.tokudb_support_xa;
@@global.tokudb_support_xa
1
'#--------------------case#2 invalid set support_xa------------------------#'
SET @@session.tokudb_support_xa = -0.6;
ERROR 42000: Incorrect argument type to variable 'tokudb_support_xa'
SET @@session.tokudb_support_xa = 1.6;
ERROR 42000: Incorrect argument type to variable 'tokudb_support_xa'
SET @@session.tokudb_support_xa = "T";
ERROR 42000: Variable 'tokudb_support_xa' can't be set to the value of 'T'
SET @@session.tokudb_support_xa = "Y";
ERROR 42000: Variable 'tokudb_support_xa' can't be set to the value of 'Y'
SET @@session.tokudb_support_xa = OF;
SELECT @@session.tokudb_support_xa;
@@session.tokudb_support_xa
0
SET @@global.tokudb_support_xa = 2;
ERROR 42000: Variable 'tokudb_support_xa' can't be set to the value of '2'
SET @@global.tokudb_support_xa = "T";
ERROR 42000: Variable 'tokudb_support_xa' can't be set to the value of 'T'
SET @@global.tokudb_support_xa = "Y";
ERROR 42000: Variable 'tokudb_support_xa' can't be set to the value of 'Y'
'#--------------------case#3 xa.test port from tokudb_mariadb/xa.test ------------------------#'
'#--------------------xa.test with tokudb_support_xa OFF ------------------------#'
SET @@global.tokudb_support_xa = OFF;
SELECT @@global.tokudb_support_xa;
@@global.tokudb_support_xa
0
create table t1 (a int) engine=tokudb;
xa start 'test1';
insert t1 values (10);
xa end 'test1';
xa prepare 'test1';
xa rollback 'test1';
select * from t1;
a
xa start 'test2';
xa start 'test-bad';
ERROR XAE07: XAER_RMFAIL: The command cannot be executed when global transaction is in the  ACTIVE state
insert t1 values (20);
xa prepare 'test2';
ERROR XAE07: XAER_RMFAIL: The command cannot be executed when global transaction is in the  ACTIVE state
xa end 'test2';
xa prepare 'test2';
xa commit 'test2';
select * from t1;
a
20
xa start 'testa','testb';
insert t1 values (30);
commit;
ERROR XAE07: XAER_RMFAIL: The command cannot be executed when global transaction is in the  ACTIVE state
xa end 'testa','testb';
begin;
ERROR XAE07: XAER_RMFAIL: The command cannot be executed when global transaction is in the  IDLE state
create table t2 (a int);
ERROR XAE07: XAER_RMFAIL: The command cannot be executed when global transaction is in the  IDLE state
xa start 'testa','testb';
ERROR XAE08: XAER_DUPID: The XID already exists
xa start 'testa','testb', 123;
ERROR XAE08: XAER_DUPID: The XID already exists
xa start 0x7465737462, 0x2030405060, 0xb;
insert t1 values (40);
xa end 'testb',' 0@P`',11;
xa prepare 'testb',0x2030405060,11;
start transaction;
ERROR XAE07: XAER_RMFAIL: The command cannot be executed when global transaction is in the  PREPARED state
xa recover;
formatID	gtrid_length	bqual_length	data
11	5	5	testb 0@P`
xa prepare 'testa','testb';
xa recover;
formatID	gtrid_length	bqual_length	data
11	5	5	testb 0@P`
1	5	5	testatestb
xa commit 'testb',0x2030405060,11;
ERROR XAE04: XAER_NOTA: Unknown XID
xa rollback 'testa','testb';
xa start 'zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz';
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your XYZ server version for the right syntax to use near '' at line 1
select * from t1;
a
20
drop table t1;
'#--------------------end------------------------#'
SET @@session.tokudb_support_xa = @session_start_value;
SELECT @@session.tokudb_support_xa;
@@session.tokudb_support_xa
1
SET @@global.tokudb_support_xa = @global_start_value;
SELECT @@global.tokudb_support_xa;
@@global.tokudb_support_xa
1