2
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
5
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
9
set timestamp=1000000000;
10
DROP TABLE IF EXISTS t1,t2,t3;
11
CREATE TABLE t1(word VARCHAR(20));
12
CREATE TABLE t2(id INT AUTO_INCREMENT NOT NULL PRIMARY KEY);
13
CREATE TABLE t3(c1 INT NOT NULL PRIMARY KEY, c2 LONGBLOB, c3 TIMESTAMP, c4 TEXT, c5 FLOAT);
15
---Test1 check table load --
16
SELECT COUNT(*) from t1;
19
SELECT COUNT(*) from t2;
22
SELECT COUNT(*) from t3;
25
SELECT * FROM t1 ORDER BY word LIMIT 5;
32
SELECT * FROM t2 ORDER BY id LIMIT 5;
39
SELECT c1, c3, c4, c5 FROM t3 ORDER BY c1 LIMIT 5;
41
1 2006-02-22 00:00:00 Tested in Texas 2.2
42
2 2006-02-22 00:00:00 Tested in Texas 4.4
43
3 2006-02-22 00:00:00 Tested in Texas 6.6
44
4 2006-02-22 00:00:00 Tested in Texas 8.8
45
5 2006-02-22 00:00:00 Tested in Texas 11
46
SELECT COUNT(*) from t1;
49
SELECT COUNT(*) from t2;
52
SELECT COUNT(*) from t3;
55
SELECT * FROM t1 ORDER BY word LIMIT 5;
62
SELECT * FROM t2 ORDER BY id LIMIT 5;
69
SELECT c1, c3, c4, c5 FROM t3 ORDER BY c1 LIMIT 5;
71
1 2006-02-22 00:00:00 Tested in Texas 2.2
72
2 2006-02-22 00:00:00 Tested in Texas 4.4
73
3 2006-02-22 00:00:00 Tested in Texas 6.6
74
4 2006-02-22 00:00:00 Tested in Texas 8.8
75
5 2006-02-22 00:00:00 Tested in Texas 11
76
insert into t1 values ("Alas");
79
--- Test 1 Dump binlog to file --
81
--- Test 1 delete tables, clean master and slave --
90
--- Test 1 Load from Dump binlog file --
92
--- Test 1 Check Load Results --
93
SELECT COUNT(*) from t1;
96
SELECT COUNT(*) from t2;
99
SELECT COUNT(*) from t3;
102
SELECT * FROM t1 ORDER BY word LIMIT 5;
109
SELECT * FROM t2 ORDER BY id LIMIT 5;
116
SELECT c1, c3, c4, c5 FROM t3 ORDER BY c1 LIMIT 5;
118
1 2006-02-22 00:00:00 Tested in Texas 2.2
119
2 2006-02-22 00:00:00 Tested in Texas 4.4
120
3 2006-02-22 00:00:00 Tested in Texas 6.6
121
4 2006-02-22 00:00:00 Tested in Texas 8.8
122
5 2006-02-22 00:00:00 Tested in Texas 11
123
SELECT COUNT(*) from t1;
126
SELECT COUNT(*) from t2;
129
SELECT COUNT(*) from t3;
132
SELECT * FROM t1 ORDER BY word LIMIT 5;
139
SELECT * FROM t2 ORDER BY id LIMIT 5;
146
SELECT c1, c3, c4, c5 FROM t3 ORDER BY c1 LIMIT 5;
148
1 2006-02-22 00:00:00 Tested in Texas 2.2
149
2 2006-02-22 00:00:00 Tested in Texas 4.4
150
3 2006-02-22 00:00:00 Tested in Texas 6.6
151
4 2006-02-22 00:00:00 Tested in Texas 8.8
152
5 2006-02-22 00:00:00 Tested in Texas 11
154
--- Test 2 position test --
155
Warning: The option '--position' is deprecated and will be removed in a future release. Please use --start-position instead.
156
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
157
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
161
SET TIMESTAMP=1000000000/*!*/;
162
SET @@session.pseudo_thread_id=999999999/*!*/;
163
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=1, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
164
SET @@session.sql_mode=0/*!*/;
165
SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
166
/*!\C latin1 *//*!*/;
167
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
168
SET @@session.lc_time_names=0/*!*/;
169
SET @@session.collation_database=DEFAULT/*!*/;
170
CREATE TABLE t3(c1 INT NOT NULL PRIMARY KEY, c2 LONGBLOB, c3 TIMESTAMP, c4 TEXT, c5 FLOAT)
174
ROLLBACK /* added by mysqlbinlog */;
175
/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/;
177
--- Test 3 First Remote test --
178
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
179
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
183
SET TIMESTAMP=1000000000/*!*/;
184
SET @@session.pseudo_thread_id=999999999/*!*/;
185
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=1, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
186
SET @@session.sql_mode=0/*!*/;
187
SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
188
/*!\C latin1 *//*!*/;
189
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
190
SET @@session.lc_time_names=0/*!*/;
191
SET @@session.collation_database=DEFAULT/*!*/;
192
DROP TABLE IF EXISTS t1,t2,t3
194
SET TIMESTAMP=1000000000/*!*/;
195
CREATE TABLE t1(word VARCHAR(20))
197
SET TIMESTAMP=1000000000/*!*/;
198
CREATE TABLE t2(id INT AUTO_INCREMENT NOT NULL PRIMARY KEY)
200
SET TIMESTAMP=1000000000/*!*/;
201
CREATE TABLE t3(c1 INT NOT NULL PRIMARY KEY, c2 LONGBLOB, c3 TIMESTAMP, c4 TEXT, c5 FLOAT)
205
ROLLBACK /* added by mysqlbinlog */;
206
/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/;
208
--- Test 4 Second Remote test --
216
SELECT COUNT(*) from t1;
219
SELECT COUNT(*) from t2;
222
SELECT COUNT(*) from t3;
225
SELECT * FROM t1 ORDER BY word LIMIT 5;
232
SELECT * FROM t2 ORDER BY id LIMIT 5;
239
SELECT c1, c3, c4, c5 FROM t3 ORDER BY c1 LIMIT 5;
241
1 2006-02-22 00:00:00 Tested in Texas 2.2
242
2 2006-02-22 00:00:00 Tested in Texas 4.4
243
3 2006-02-22 00:00:00 Tested in Texas 6.6
244
4 2006-02-22 00:00:00 Tested in Texas 8.8
245
5 2006-02-22 00:00:00 Tested in Texas 11
246
SELECT COUNT(*) from t1;
249
SELECT COUNT(*) from t2;
252
SELECT COUNT(*) from t3;
255
SELECT * FROM t1 ORDER BY word LIMIT 5;
262
SELECT * FROM t2 ORDER BY id LIMIT 5;
269
SELECT c1, c3, c4, c5 FROM t3 ORDER BY c1 LIMIT 5;
271
1 2006-02-22 00:00:00 Tested in Texas 2.2
272
2 2006-02-22 00:00:00 Tested in Texas 4.4
273
3 2006-02-22 00:00:00 Tested in Texas 6.6
274
4 2006-02-22 00:00:00 Tested in Texas 8.8
275
5 2006-02-22 00:00:00 Tested in Texas 11
277
--- Test 5 LOAD DATA --
278
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
279
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
283
ROLLBACK /* added by mysqlbinlog */;
284
/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/;
286
--- Test 6 reading stdin --
287
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
288
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
292
SET TIMESTAMP=1000000000/*!*/;
293
SET @@session.pseudo_thread_id=999999999/*!*/;
294
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=1, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
295
SET @@session.sql_mode=0/*!*/;
296
SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
297
/*!\C latin1 *//*!*/;
298
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
299
SET @@session.lc_time_names=0/*!*/;
300
SET @@session.collation_database=DEFAULT/*!*/;
301
DROP TABLE IF EXISTS t1,t2,t3
303
SET TIMESTAMP=1000000000/*!*/;
304
CREATE TABLE t1(word VARCHAR(20))
306
SET TIMESTAMP=1000000000/*!*/;
307
CREATE TABLE t2(id INT AUTO_INCREMENT NOT NULL PRIMARY KEY)
309
SET TIMESTAMP=1000000000/*!*/;
310
CREATE TABLE t3(c1 INT NOT NULL PRIMARY KEY, c2 LONGBLOB, c3 TIMESTAMP, c4 TEXT, c5 FLOAT)
314
ROLLBACK /* added by mysqlbinlog */;
315
/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/;
317
--- Test 7 reading stdin w/position --
318
Warning: The option '--position' is deprecated and will be removed in a future release. Please use --start-position instead.
319
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
320
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
324
SET TIMESTAMP=1000000000/*!*/;
325
SET @@session.pseudo_thread_id=999999999/*!*/;
326
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=1, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
327
SET @@session.sql_mode=0/*!*/;
328
SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
329
/*!\C latin1 *//*!*/;
330
SET @@session.character_set_client=8,@@session.collation_connection=8,@@session.collation_server=8/*!*/;
331
SET @@session.lc_time_names=0/*!*/;
332
SET @@session.collation_database=DEFAULT/*!*/;
333
CREATE TABLE t3(c1 INT NOT NULL PRIMARY KEY, c2 LONGBLOB, c3 TIMESTAMP, c4 TEXT, c5 FLOAT)
337
ROLLBACK /* added by mysqlbinlog */;
338
/*!50003 SET COMPLETION_TYPE=@OLD_COMPLETION_TYPE*/;
340
--- Test 8 switch internal charset --
345
create table t4 (f text character set utf8);
346
create table t5 (f text character set cp932);
348
rename table t4 to t04, t5 to t05;
349
select HEX(f) from t04;
352
select HEX(f) from t4;
355
select HEX(f) from t05;
358
select HEX(f) from t5;
361
select HEX(f) from t04;
364
select HEX(f) from t4;
367
select HEX(f) from t05;
370
select HEX(f) from t5;
375
DROP TABLE IF EXISTS t1;
376
CREATE TABLE t1 (a INT NOT NULL KEY, b INT);
377
INSERT INTO t1 VALUES(1,1);
382
DROP TABLE IF EXISTS t1, t2, t3, t04, t05, t4, t5;