17
17
18
18
--connection master
19
19
CREATE TABLE t1 (a INT PRIMARY KEY);
20
- SET @debug_saved= @@ GLOBAL.DEBUG;
20
+ SET @@ GLOBAL.DEBUG= @debug_saved ;
21
21
SET @@GLOBAL.DEBUG= '+d,PKE_assert_single_primary_key_generated_insert';
22
22
INSERT INTO t1 VALUES(1);
23
23
SET @@GLOBAL.DEBUG= @debug_saved;
@@ -28,23 +28,8 @@ SET @@GLOBAL.DEBUG= @debug_saved;
28
28
DROP TABLE t1;
29
29
--source include/rpl_sync.inc
30
30
31
- # tests both writeset algorithm (with and without collation)
32
- --connection master
33
- CREATE TABLE t1 (a BINARY(1) PRIMARY KEY);
34
- SET @@GLOBAL.DEBUG= @debug_saved;
35
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_single_primary_key_generated_insert_collation';
36
- INSERT INTO t1 VALUES(1);
37
- SET @@GLOBAL.DEBUG= @debug_saved;
38
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_single_primary_key_generated_update_collation';
39
- UPDATE t1 SET a=3 WHERE a=1;
40
- SET @@GLOBAL.DEBUG= @debug_saved;
41
- --source include/rpl_sync.inc
42
- DROP TABLE t1;
43
- --source include/rpl_sync.inc
44
-
45
31
# Table with multi values pimary key field with insert and update
46
32
47
- --connection master
48
33
CREATE TABLE t1(a INT, b INT, PRIMARY KEY(a, b));
49
34
SET @@GLOBAL.DEBUG= @debug_saved;
50
35
SET @@GLOBAL.DEBUG= '+d,PKE_assert_multi_primary_key_generated_insert';
@@ -57,20 +42,6 @@ SET @@GLOBAL.DEBUG= @debug_saved;
57
42
DROP TABLE t1;
58
43
--source include/rpl_sync.inc
59
44
60
- # tests both writeset algorithm (with and without collation)
61
- --connection master
62
- CREATE TABLE t1(a BINARY(1), b BINARY(1), PRIMARY KEY(a, b));
63
- SET @@GLOBAL.DEBUG= @debug_saved;
64
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_multi_primary_key_generated_insert_collation';
65
- INSERT INTO t1 VALUE(1, 2);
66
- SET @@GLOBAL.DEBUG= @debug_saved;
67
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_multi_primary_key_generated_update_collation';
68
- UPDATE t1 SET a=3 WHERE a=1;
69
- SET @@GLOBAL.DEBUG= @debug_saved;
70
- --source include/rpl_sync.inc
71
- DROP TABLE t1;
72
- --source include/rpl_sync.inc
73
-
74
45
# Table with single primary key and multiple unique key with insert and
75
46
# updates.
76
47
@@ -86,23 +57,9 @@ UPDATE t1 SET c1=5 WHERE c1=1;
86
57
DROP TABLE t1;
87
58
--source include/rpl_sync.inc
88
59
89
- # tests both writeset algorithm (with and without collation)
90
- --connection master
91
- CREATE TABLE t1 (c1 BINARY(1) PRIMARY KEY, c2 BINARY(1) NOT NULL UNIQUE, c3 BINARY(1) NOT NULL UNIQUE);
92
- SET @@GLOBAL.DEBUG= @debug_saved;
93
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_single_primary_unique_key_generated_insert_collation';
94
- INSERT INTO t1 VALUES (1, 2, 3);
95
- SET @@GLOBAL.DEBUG= @debug_saved;
96
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_single_primary_unique_key_generated_update_collation';
97
- UPDATE t1 SET c1=5 WHERE c1=1;
98
- --source include/rpl_sync.inc
99
- DROP TABLE t1;
100
- --source include/rpl_sync.inc
101
-
102
60
# Table with multi valued primary key and multiple unique key with insert and
103
61
# updates.
104
62
105
- --connection master
106
63
CREATE TABLE t1 (a INT, d INT, b INT NOT NULL UNIQUE, c INT NOT NULL UNIQUE, PRIMARY KEY(a, d));
107
64
SET @@GLOBAL.DEBUG= @debug_saved;
108
65
SET @@GLOBAL.DEBUG= '+d,PKE_assert_multi_primary_unique_key_generated_insert';
@@ -115,20 +72,6 @@ SET @@GLOBAL.DEBUG= @debug_saved;
115
72
DROP TABLE t1;
116
73
--source include/rpl_sync.inc
117
74
118
- # tests both writeset algorithm (with and without collation)
119
- --connection master
120
- CREATE TABLE t1 (a BINARY(1), d BINARY(1), b BINARY(1) NOT NULL UNIQUE, c BINARY(1) NOT NULL UNIQUE, PRIMARY KEY(a, d));
121
- SET @@GLOBAL.DEBUG= @debug_saved;
122
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_multi_primary_unique_key_generated_insert_collation';
123
- INSERT INTO t1 VALUES(1, 2, 3, 4);
124
- SET @@GLOBAL.DEBUG= @debug_saved;
125
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_multi_primary_unique_key_generated_update_collation';
126
- UPDATE t1 SET a=5 WHERE a=1;
127
- SET @@GLOBAL.DEBUG= @debug_saved;
128
- --source include/rpl_sync.inc
129
- DROP TABLE t1;
130
- --source include/rpl_sync.inc
131
-
132
75
# Table with Primary Key + Unique Key and Foreign Key
133
76
134
77
--connection master
@@ -154,27 +97,4 @@ DROP TABLE t2;
154
97
DROP TABLE t1;
155
98
--source include/rpl_sync.inc
156
99
157
- # tests both writeset algorithm (with and without collation)
158
- --connection master
159
- CREATE TABLE t1 (a BINARY(1) PRIMARY KEY);
160
- CREATE TABLE t2 (b BINARY(1) PRIMARY KEY);
161
- CREATE TABLE t3 (c1 BINARY(1), c2 BINARY(1) NOT NULL UNIQUE, PRIMARY KEY(c1, c2), FOREIGN KEY(c1) REFERENCES t1(a), FOREIGN KEY(c2) REFERENCES t2(b));
162
-
163
- INSERT INTO t1 VALUES (1);
164
- INSERT INTO t2 VALUES (5);
165
- SET @@GLOBAL.DEBUG= @debug_saved;
166
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_multi_foreign_key_generated_insert_collation';
167
- INSERT INTO t3 values(1,5);
168
- SET @@GLOBAL.DEBUG= @debug_saved;
169
- INSERT INTO t1 VALUES (3);
170
- --source include/rpl_sync.inc
171
- SET @@GLOBAL.DEBUG= '+d,PKE_assert_multi_foreign_key_generated_update_collation';
172
- UPDATE t3 SET c1=3 WHERE c1=1;
173
- --source include/rpl_sync.inc
174
- SET @@GLOBAL.DEBUG= @debug_saved;
175
- DROP TABLE t3;
176
- DROP TABLE t2;
177
- DROP TABLE t1;
178
- --source include/rpl_sync.inc
179
-
180
100
--source include/rpl_end.inc
0 commit comments