mysqldump.result 193 KB
Newer Older
1 2 3
# Bug#37938 Test "mysqldump" lacks various insert statements
# Turn off concurrent inserts to avoid random errors
# NOTE:  We reset the variable back to saved value at the end of test
4 5
SET @OLD_CONCURRENT_INSERT = @@GLOBAL.CONCURRENT_INSERT;
SET @@GLOBAL.CONCURRENT_INSERT = 0;
unknown's avatar
unknown committed
6
DROP TABLE IF EXISTS t1, `"t"1`, t1aa, t2, t2aa, t3;
unknown's avatar
unknown committed
7
drop database if exists mysqldump_test_db;
8
drop database if exists db1;
9
drop database if exists db2;
unknown's avatar
unknown committed
10
drop view if exists v1, v2, v3;
Matthias Leich's avatar
Matthias Leich committed
11
CREATE TABLE t1(a INT, KEY (a)) KEY_BLOCK_SIZE=1024;
unknown's avatar
unknown committed
12 13
INSERT INTO t1 VALUES (1), (2);
<?xml version="1.0"?>
14
<mysqldump xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
unknown's avatar
unknown committed
15
<database name="test">
unknown's avatar
unknown committed
16
	<table_structure name="t1">
unknown's avatar
unknown committed
17 18
		<field Field="a" Type="int(11)" Null="YES" Key="MUL" Extra="" />
		<key Table="t1" Non_unique="1" Key_name="a" Seq_in_index="1" Column_name="a" Collation="A" Null="YES" Index_type="BTREE" Comment="" />
unknown's avatar
unknown committed
19 20
	</table_structure>
	<table_data name="t1">
unknown's avatar
unknown committed
21 22 23 24 25 26
	<row>
		<field name="a">1</field>
	</row>
	<row>
		<field name="a">2</field>
	</row>
unknown's avatar
unknown committed
27
	</table_data>
unknown's avatar
unknown committed
28 29
</database>
</mysqldump>
30
DROP TABLE t1;
unknown's avatar
unknown committed
31
#
32
# Bug#2005 Long decimal comparison bug.
unknown's avatar
unknown committed
33
#
unknown's avatar
unknown committed
34
CREATE TABLE t1 (a decimal(64, 20));
35 36
INSERT INTO t1 VALUES ("1234567890123456789012345678901234567890"),
("0987654321098765432109876543210987654321");
37 38
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
39
CREATE TABLE `t1` (
40
  `a` decimal(64,20) DEFAULT NULL
unknown's avatar
unknown committed
41
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
42
/*!40101 SET character_set_client = @saved_cs_client */;
43
INSERT INTO `t1` VALUES (1234567890123456789012345678901234567890.00000000000000000000),(987654321098765432109876543210987654321.00000000000000000000);
unknown's avatar
unknown committed
44
DROP TABLE t1;
unknown's avatar
unknown committed
45
#
46
# Bug#2055 mysqldump should replace "-inf" numeric field values with "NULL"
unknown's avatar
unknown committed
47
#
unknown's avatar
unknown committed
48
CREATE TABLE t1 (a double);
unknown's avatar
unknown committed
49 50
INSERT INTO t1 VALUES ('-9e999999');
Warnings:
51
Warning	1264	Out of range value for column 'a' at row 1
52 53
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
54
CREATE TABLE `t1` (
55
  `a` double DEFAULT NULL
unknown's avatar
unknown committed
56
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
57
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
58 59
INSERT INTO `t1` VALUES (RES);
DROP TABLE t1;
unknown's avatar
unknown committed
60
#
61
# Bug#3361 mysqldump quotes DECIMAL values inconsistently
unknown's avatar
unknown committed
62
#
unknown's avatar
unknown committed
63 64 65 66 67 68 69 70 71 72
CREATE TABLE t1 (a DECIMAL(10,5), b FLOAT);
INSERT INTO t1 VALUES (1.2345, 2.3456);
INSERT INTO t1 VALUES ('1.2345', 2.3456);
INSERT INTO t1 VALUES ("1.2345", 2.3456);
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='ANSI_QUOTES';
INSERT INTO t1 VALUES (1.2345, 2.3456);
INSERT INTO t1 VALUES ('1.2345', 2.3456);
INSERT INTO t1 VALUES ("1.2345", 2.3456);
ERROR 42S22: Unknown column '1.2345' in 'field list'
SET SQL_MODE=@OLD_SQL_MODE;
73 74
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
75
CREATE TABLE `t1` (
76 77
  `a` decimal(10,5) DEFAULT NULL,
  `b` float DEFAULT NULL
unknown's avatar
unknown committed
78
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
79
/*!40101 SET character_set_client = @saved_cs_client */;
80
INSERT INTO `t1` VALUES (1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456);
81 82
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
83
CREATE TABLE `t1` (
84 85
  `a` decimal(10,5) DEFAULT NULL,
  `b` float DEFAULT NULL
unknown's avatar
unknown committed
86
);
87
/*!40101 SET character_set_client = @saved_cs_client */;
88
INSERT INTO `t1` VALUES (1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456);
unknown's avatar
unknown committed
89

90 91 92 93
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
94 95
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
96 97
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
98
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
99
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
unknown's avatar
unknown committed
100
DROP TABLE IF EXISTS `t1`;
101 102
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
103
CREATE TABLE `t1` (
104 105
  `a` decimal(10,5) DEFAULT NULL,
  `b` float DEFAULT NULL
unknown's avatar
unknown committed
106
);
107
/*!40101 SET character_set_client = @saved_cs_client */;
108

unknown's avatar
unknown committed
109
LOCK TABLES `t1` WRITE;
110
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
111
INSERT INTO `t1` VALUES (1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456);
unknown's avatar
unknown committed
112
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
113
UNLOCK TABLES;
unknown's avatar
unknown committed
114
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
115 116 117 118 119

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
120 121
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
122
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
123

unknown's avatar
unknown committed
124 125
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
126 127
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
128
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
129
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
130 131
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
132
CREATE TABLE `t1` (
133 134
  `a` decimal(10,5) DEFAULT NULL,
  `b` float DEFAULT NULL
unknown's avatar
unknown committed
135
);
136
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
137

138
INSERT INTO `t1` VALUES (1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456),(1.23450,2.3456);
unknown's avatar
unknown committed
139
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
140 141 142 143

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
144
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
145

unknown's avatar
unknown committed
146
DROP TABLE t1;
147 148 149
CREATE TABLE t1(a int, b text, c varchar(3));
INSERT INTO t1 VALUES (1, "test", "tes"), (2, "TEST", "TES");
<?xml version="1.0"?>
150
<mysqldump xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
151 152 153 154
<database name="test">
	<table_structure name="t1">
		<field Field="a" Type="int(11)" Null="YES" Key="" Extra="" />
		<field Field="b" Type="text" Null="YES" Key="" Extra="" />
unknown's avatar
unknown committed
155
		<field Field="c" Type="varchar(3)" Null="YES" Key="" Extra="" />
156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171
	</table_structure>
	<table_data name="t1">
	<row>
		<field name="a">1</field>
		<field name="b">test</field>
		<field name="c">tes</field>
	</row>
	<row>
		<field name="a">2</field>
		<field name="b">TEST</field>
		<field name="c">TES</field>
	</row>
	</table_data>
</database>
</mysqldump>
DROP TABLE t1;
unknown's avatar
unknown committed
172
#
173
# Bug#1707 mysqldump -X does't quote field and table names
unknown's avatar
unknown committed
174
#
175 176
CREATE TABLE t1 (`a"b"` char(2));
INSERT INTO t1 VALUES ("1\""), ("\"2");
unknown's avatar
unknown committed
177
<?xml version="1.0"?>
178
<mysqldump xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
unknown's avatar
unknown committed
179
<database name="test">
180
	<table_structure name="t1">
181
		<field Field="a&quot;b&quot;" Type="char(2)" Null="YES" Key="" Extra="" />
unknown's avatar
unknown committed
182
	</table_structure>
183
	<table_data name="t1">
unknown's avatar
unknown committed
184
	<row>
unknown's avatar
unknown committed
185
		<field name="a&quot;b&quot;">1&quot;</field>
unknown's avatar
unknown committed
186 187
	</row>
	<row>
unknown's avatar
unknown committed
188
		<field name="a&quot;b&quot;">&quot;2</field>
unknown's avatar
unknown committed
189 190 191 192
	</row>
	</table_data>
</database>
</mysqldump>
193
DROP TABLE t1;
unknown's avatar
unknown committed
194
#
195 196
# Bug#1994 mysqldump does not correctly dump UCS2 data
# Bug#4261 mysqldump 10.7 (mysql 4.1.2) --skip-extended-insert drops NULL from inserts
unknown's avatar
unknown committed
197
#
198
CREATE TABLE t1 (a  VARCHAR(255)) DEFAULT CHARSET koi8r;
199
INSERT INTO t1  VALUES (_koi8r x'C1C2C3C4C5'), (NULL);
unknown's avatar
unknown committed
200

201 202 203 204
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
205 206
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
207 208
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
209
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
210
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
unknown's avatar
unknown committed
211
DROP TABLE IF EXISTS `t1`;
212 213
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
214
CREATE TABLE `t1` (
215
  `a` varchar(255) DEFAULT NULL
216
) ENGINE=MyISAM DEFAULT CHARSET=koi8r;
217
/*!40101 SET character_set_client = @saved_cs_client */;
218

unknown's avatar
unknown committed
219
LOCK TABLES `t1` WRITE;
220
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
221
INSERT INTO `t1` VALUES ('абцде');
222
INSERT INTO `t1` VALUES (NULL);
unknown's avatar
unknown committed
223
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
224
UNLOCK TABLES;
unknown's avatar
unknown committed
225
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
226 227 228 229 230

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
231 232
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
233
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
234

235
DROP TABLE t1;
unknown's avatar
unknown committed
236
#
237
# Bug#2634 mysqldump in --compatible=mysql4
unknown's avatar
unknown committed
238
#
unknown's avatar
unknown committed
239 240
CREATE TABLE t1 (a int) ENGINE=MYISAM;
INSERT INTO t1 VALUES (1), (2);
unknown's avatar
unknown committed
241 242
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
243 244
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
245
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,MYSQL40' */;
246
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
unknown's avatar
unknown committed
247 248
DROP TABLE IF EXISTS `t1`;
CREATE TABLE `t1` (
249
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
250 251 252
) TYPE=MyISAM;

LOCK TABLES `t1` WRITE;
253
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
254 255
INSERT INTO `t1` VALUES (1),(2);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
256
UNLOCK TABLES;
unknown's avatar
unknown committed
257
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
258 259 260 261

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
262
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
263

unknown's avatar
unknown committed
264 265
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
266 267
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
268
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,MYSQL323' */;
269
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
unknown's avatar
unknown committed
270 271
DROP TABLE IF EXISTS `t1`;
CREATE TABLE `t1` (
272
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
273 274 275
) TYPE=MyISAM;

LOCK TABLES `t1` WRITE;
276
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
277 278
INSERT INTO `t1` VALUES (1),(2);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
279
UNLOCK TABLES;
unknown's avatar
unknown committed
280
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
281 282 283 284

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
285
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
286

unknown's avatar
unknown committed
287
DROP TABLE t1;
unknown's avatar
unknown committed
288
#
289
# Bug#2592 mysqldump doesn't quote "tricky" names correctly
unknown's avatar
unknown committed
290
#
291
create table ```a` (i int);
292 293
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
294
CREATE TABLE ```a` (
295
  `i` int(11) DEFAULT NULL
296
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
297
/*!40101 SET character_set_client = @saved_cs_client */;
298
drop table ```a`;
unknown's avatar
unknown committed
299
#
300
# Bug#2591 mysqldump quotes names inconsistently
unknown's avatar
unknown committed
301
#
302
create table t1(a int);
303

304 305 306 307
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
308 309
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
310 311
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
312
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
313
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
314
DROP TABLE IF EXISTS `t1`;
315 316
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
317
CREATE TABLE `t1` (
318
  `a` int(11) DEFAULT NULL
319
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
320
/*!40101 SET character_set_client = @saved_cs_client */;
321 322

LOCK TABLES `t1` WRITE;
323
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
324
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
325
UNLOCK TABLES;
unknown's avatar
unknown committed
326
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
327 328 329 330 331

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
332 333
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
334
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
335

unknown's avatar
unknown committed
336 337
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
338 339
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
340
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,ANSI' */;
341
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
342
DROP TABLE IF EXISTS "t1";
343 344
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
345
CREATE TABLE "t1" (
346
  "a" int(11) DEFAULT NULL
347
);
348
/*!40101 SET character_set_client = @saved_cs_client */;
349 350

LOCK TABLES "t1" WRITE;
351
/*!40000 ALTER TABLE "t1" DISABLE KEYS */;
352
/*!40000 ALTER TABLE "t1" ENABLE KEYS */;
353
UNLOCK TABLES;
unknown's avatar
unknown committed
354
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
355 356 357 358

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
359
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
360

361 362
set global sql_mode='ANSI_QUOTES';

363 364 365 366
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
367 368
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
369 370
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
371
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
372
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
373
DROP TABLE IF EXISTS `t1`;
374 375
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
376
CREATE TABLE `t1` (
377
  `a` int(11) DEFAULT NULL
378
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
379
/*!40101 SET character_set_client = @saved_cs_client */;
380 381

LOCK TABLES `t1` WRITE;
382
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
383
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
384
UNLOCK TABLES;
unknown's avatar
unknown committed
385
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
386 387 388 389 390

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
391 392
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
393
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
394

unknown's avatar
unknown committed
395 396
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
397 398
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
399
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,ANSI' */;
400
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
401
DROP TABLE IF EXISTS "t1";
402 403
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
404
CREATE TABLE "t1" (
405
  "a" int(11) DEFAULT NULL
406
);
407
/*!40101 SET character_set_client = @saved_cs_client */;
408 409

LOCK TABLES "t1" WRITE;
410
/*!40000 ALTER TABLE "t1" DISABLE KEYS */;
411
/*!40000 ALTER TABLE "t1" ENABLE KEYS */;
412
UNLOCK TABLES;
unknown's avatar
unknown committed
413
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
414 415 416 417

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
418
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
419

420
set global sql_mode='';
421
drop table t1;
unknown's avatar
unknown committed
422
#
423
# Bug#2705 mysqldump --tab extra output
unknown's avatar
unknown committed
424
#
425
create table t1(a int);
426 427
insert into t1 values (1),(2),(3);

428 429 430 431
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
432 433
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
434
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='' */;
435
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
436
DROP TABLE IF EXISTS `t1`;
437 438
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
439
CREATE TABLE `t1` (
440
  `a` int(11) DEFAULT NULL
441
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
442
/*!40101 SET character_set_client = @saved_cs_client */;
443

unknown's avatar
unknown committed
444
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
445 446 447

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
448 449
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
450
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
451

452 453 454 455
1
2
3
drop table t1;
unknown's avatar
unknown committed
456
#
457
# Bug#6101 create database problem
unknown's avatar
unknown committed
458
#
459 460 461 462 463

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
464 465
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
466 467
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
468
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
469
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
470 471 472 473

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `test`;
unknown's avatar
unknown committed
474
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
475 476 477 478 479 480 481

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
482
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
483

484 485 486 487 488 489
create database mysqldump_test_db character set latin2 collate latin2_bin;

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
490 491
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
492 493
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
494
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
495
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
496 497 498 499

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `mysqldump_test_db` /*!40100 DEFAULT CHARACTER SET latin2 COLLATE latin2_bin */;

USE `mysqldump_test_db`;
unknown's avatar
unknown committed
500
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
501 502 503 504 505 506 507

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
508
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
509

510
drop database mysqldump_test_db;
unknown's avatar
unknown committed
511
#
512
# Bug#7020 mysqldump --compatible=mysql40 should set --skip-set-charset --default-char...
unknown's avatar
unknown committed
513 514 515 516
# Check that we don't dump in UTF8 in compatible mode by default,
# but use the default compiled values, or the values given in
# --default-character-set=xxx. However, we should dump in UTF8
# if it is explicitely set.
517
CREATE TABLE t1 (a  CHAR(10));
unknown's avatar
unknown committed
518
INSERT INTO t1  VALUES (_latin1 '');
519 520 521 522 523

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
524 525
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
526 527
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
528
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
529
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
530
DROP TABLE IF EXISTS `t1`;
531 532
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
533
CREATE TABLE `t1` (
534
  `a` char(10) DEFAULT NULL
535
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
536
/*!40101 SET character_set_client = @saved_cs_client */;
537 538

LOCK TABLES `t1` WRITE;
539
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
540 541
INSERT INTO `t1` VALUES ('ÄÖÜß');
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
542
UNLOCK TABLES;
unknown's avatar
unknown committed
543
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
544 545 546 547 548 549 550

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
551
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
552

unknown's avatar
unknown committed
553
#
554 555
# Bug#8063 make test mysqldump [ fail ]
# We cannot test this command because its output depends
unknown's avatar
unknown committed
556 557 558 559
# on --default-character-set incompiled into "mysqldump" program.
# If the future we can move this command into a separate test with
# checking that "mysqldump" is compiled with "latin1"
#
unknown's avatar
unknown committed
560 561
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
562 563
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
564
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,MYSQL323' */;
565
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
566 567
DROP TABLE IF EXISTS `t1`;
CREATE TABLE `t1` (
568
  `a` char(10) DEFAULT NULL
569 570 571
) TYPE=MyISAM;

LOCK TABLES `t1` WRITE;
572
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
573
INSERT INTO `t1` VALUES ('');
574
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
575
UNLOCK TABLES;
unknown's avatar
unknown committed
576
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
577 578 579 580

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
581
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
582

unknown's avatar
unknown committed
583 584
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
585 586
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
587
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,MYSQL323' */;
588
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
589 590
DROP TABLE IF EXISTS `t1`;
CREATE TABLE `t1` (
591
  `a` char(10) DEFAULT NULL
592 593 594
) TYPE=MyISAM;

LOCK TABLES `t1` WRITE;
595
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
596
INSERT INTO `t1` VALUES ('');
597
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
598
UNLOCK TABLES;
unknown's avatar
unknown committed
599
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
600 601 602 603

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
604
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
605

unknown's avatar
unknown committed
606 607
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
608 609
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
610
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,MYSQL323' */;
611
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
612 613
DROP TABLE IF EXISTS `t1`;
CREATE TABLE `t1` (
614
  `a` char(10) DEFAULT NULL
615 616 617
) TYPE=MyISAM;

LOCK TABLES `t1` WRITE;
618
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
619 620
INSERT INTO `t1` VALUES ('ÄÖÜß');
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
621
UNLOCK TABLES;
unknown's avatar
unknown committed
622
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
623 624 625 626

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
627
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
628

629
DROP TABLE t1;
unknown's avatar
unknown committed
630
#
631
# WL#2319 Exclude Tables from dump
unknown's avatar
unknown committed
632
#
633 634 635 636 637 638 639 640 641
CREATE TABLE t1 (a int);
CREATE TABLE t2 (a int);
INSERT INTO t1 VALUES (1),(2),(3);
INSERT INTO t2 VALUES (4),(5),(6);

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
642 643
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
644 645
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
646
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
647
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
648
DROP TABLE IF EXISTS `t2`;
649 650
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
651
CREATE TABLE `t2` (
652
  `a` int(11) DEFAULT NULL
653
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
654
/*!40101 SET character_set_client = @saved_cs_client */;
655 656

LOCK TABLES `t2` WRITE;
657
/*!40000 ALTER TABLE `t2` DISABLE KEYS */;
658 659
INSERT INTO `t2` VALUES (4),(5),(6);
/*!40000 ALTER TABLE `t2` ENABLE KEYS */;
660
UNLOCK TABLES;
unknown's avatar
unknown committed
661
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
662 663 664 665 666 667 668

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
669
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
670

671 672
DROP TABLE t1;
DROP TABLE t2;
unknown's avatar
unknown committed
673
#
674
# Bug#8830 mysqldump --skip-extended-insert causes --hex-blob to dump wrong values
unknown's avatar
unknown committed
675
#
676 677 678 679 680 681 682
CREATE TABLE t1 (`b` blob);
INSERT INTO `t1` VALUES (0x602010000280100005E71A);

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
683 684
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
685 686 687 688 689
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
690 691
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
692 693 694
CREATE TABLE `t1` (
  `b` blob
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
695
/*!40101 SET character_set_client = @saved_cs_client */;
696 697

LOCK TABLES `t1` WRITE;
698
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
699 700
INSERT INTO `t1` VALUES (0x602010000280100005E71A);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
701
UNLOCK TABLES;
unknown's avatar
unknown committed
702
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
703 704 705 706 707 708 709 710 711

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

unknown's avatar
unknown committed
712
DROP TABLE t1;
unknown's avatar
unknown committed
713 714 715
#
# Test for --insert-ignore
#
716
CREATE TABLE t1 (a INT);
unknown's avatar
unknown committed
717 718
INSERT INTO t1 VALUES (1),(2),(3);
INSERT INTO t1 VALUES (4),(5),(6);
unknown's avatar
unknown committed
719 720 721 722 723

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
724 725
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
726 727 728 729 730
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
731 732
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
733
CREATE TABLE `t1` (
734
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
735
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
736
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
737 738

LOCK TABLES `t1` WRITE;
739
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
740
INSERT  IGNORE INTO `t1` VALUES (1),(2),(3),(4),(5),(6);
unknown's avatar
unknown committed
741
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
742
UNLOCK TABLES;
unknown's avatar
unknown committed
743
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
744 745 746 747 748 749 750 751 752 753 754 755 756 757

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;


/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
758 759
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
760 761 762 763 764
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
765 766
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
767
CREATE TABLE `t1` (
768
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
769
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
770
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
771 772

/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
773
INSERT  DELAYED IGNORE INTO `t1` VALUES (1),(2),(3),(4),(5),(6);
unknown's avatar
unknown committed
774
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
775
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
776 777 778 779 780 781 782 783 784

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

785
DROP TABLE t1;
unknown's avatar
unknown committed
786
#
787 788 789
# Bug#10286 mysqldump -c crashes on table that has many fields with long
#           names
#
790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126
create table t1 (
F_c4ca4238a0b923820dcc509a6f75849b int,
F_c81e728d9d4c2f636f067f89cc14862c int,
F_eccbc87e4b5ce2fe28308fd9f2a7baf3 int,
F_a87ff679a2f3e71d9181a67b7542122c int,
F_e4da3b7fbbce2345d7772b0674a318d5 int,
F_1679091c5a880faf6fb5e6087eb1b2dc int,
F_8f14e45fceea167a5a36dedd4bea2543 int,
F_c9f0f895fb98ab9159f51fd0297e236d int,
F_45c48cce2e2d7fbdea1afc51c7c6ad26 int,
F_d3d9446802a44259755d38e6d163e820 int,
F_6512bd43d9caa6e02c990b0a82652dca int,
F_c20ad4d76fe97759aa27a0c99bff6710 int,
F_c51ce410c124a10e0db5e4b97fc2af39 int,
F_aab3238922bcc25a6f606eb525ffdc56 int,
F_9bf31c7ff062936a96d3c8bd1f8f2ff3 int,
F_c74d97b01eae257e44aa9d5bade97baf int,
F_70efdf2ec9b086079795c442636b55fb int,
F_6f4922f45568161a8cdf4ad2299f6d23 int,
F_1f0e3dad99908345f7439f8ffabdffc4 int,
F_98f13708210194c475687be6106a3b84 int,
F_3c59dc048e8850243be8079a5c74d079 int,
F_b6d767d2f8ed5d21a44b0e5886680cb9 int,
F_37693cfc748049e45d87b8c7d8b9aacd int,
F_1ff1de774005f8da13f42943881c655f int,
F_8e296a067a37563370ded05f5a3bf3ec int,
F_4e732ced3463d06de0ca9a15b6153677 int,
F_02e74f10e0327ad868d138f2b4fdd6f0 int,
F_33e75ff09dd601bbe69f351039152189 int,
F_6ea9ab1baa0efb9e19094440c317e21b int,
F_34173cb38f07f89ddbebc2ac9128303f int,
F_c16a5320fa475530d9583c34fd356ef5 int,
F_6364d3f0f495b6ab9dcf8d3b5c6e0b01 int,
F_182be0c5cdcd5072bb1864cdee4d3d6e int,
F_e369853df766fa44e1ed0ff613f563bd int,
F_1c383cd30b7c298ab50293adfecb7b18 int,
F_19ca14e7ea6328a42e0eb13d585e4c22 int,
F_a5bfc9e07964f8dddeb95fc584cd965d int,
F_a5771bce93e200c36f7cd9dfd0e5deaa int,
F_d67d8ab4f4c10bf22aa353e27879133c int,
F_d645920e395fedad7bbbed0eca3fe2e0 int,
F_3416a75f4cea9109507cacd8e2f2aefc int,
F_a1d0c6e83f027327d8461063f4ac58a6 int,
F_17e62166fc8586dfa4d1bc0e1742c08b int,
F_f7177163c833dff4b38fc8d2872f1ec6 int,
F_6c8349cc7260ae62e3b1396831a8398f int,
F_d9d4f495e875a2e075a1a4a6e1b9770f int,
F_67c6a1e7ce56d3d6fa748ab6d9af3fd7 int,
F_642e92efb79421734881b53e1e1b18b6 int,
F_f457c545a9ded88f18ecee47145a72c0 int,
F_c0c7c76d30bd3dcaefc96f40275bdc0a int,
F_2838023a778dfaecdc212708f721b788 int,
F_9a1158154dfa42caddbd0694a4e9bdc8 int,
F_d82c8d1619ad8176d665453cfb2e55f0 int,
F_a684eceee76fc522773286a895bc8436 int,
F_b53b3a3d6ab90ce0268229151c9bde11 int,
F_9f61408e3afb633e50cdf1b20de6f466 int,
F_72b32a1f754ba1c09b3695e0cb6cde7f int,
F_66f041e16a60928b05a7e228a89c3799 int,
F_093f65e080a295f8076b1c5722a46aa2 int,
F_072b030ba126b2f4b2374f342be9ed44 int,
F_7f39f8317fbdb1988ef4c628eba02591 int,
F_44f683a84163b3523afe57c2e008bc8c int,
F_03afdbd66e7929b125f8597834fa83a4 int,
F_ea5d2f1c4608232e07d3aa3d998e5135 int,
F_fc490ca45c00b1249bbe3554a4fdf6fb int,
F_3295c76acbf4caaed33c36b1b5fc2cb1 int,
F_735b90b4568125ed6c3f678819b6e058 int,
F_a3f390d88e4c41f2747bfa2f1b5f87db int,
F_14bfa6bb14875e45bba028a21ed38046 int,
F_7cbbc409ec990f19c78c75bd1e06f215 int,
F_e2c420d928d4bf8ce0ff2ec19b371514 int,
F_32bb90e8976aab5298d5da10fe66f21d int,
F_d2ddea18f00665ce8623e36bd4e3c7c5 int,
F_ad61ab143223efbc24c7d2583be69251 int,
F_d09bf41544a3365a46c9077ebb5e35c3 int,
F_fbd7939d674997cdb4692d34de8633c4 int,
F_28dd2c7955ce926456240b2ff0100bde int,
F_35f4a8d465e6e1edc05f3d8ab658c551 int,
F_d1fe173d08e959397adf34b1d77e88d7 int,
F_f033ab37c30201f73f142449d037028d int,
F_43ec517d68b6edd3015b3edc9a11367b int,
F_9778d5d219c5080b9a6a17bef029331c int,
F_fe9fc289c3ff0af142b6d3bead98a923 int,
F_68d30a9594728bc39aa24be94b319d21 int,
F_3ef815416f775098fe977004015c6193 int,
F_93db85ed909c13838ff95ccfa94cebd9 int,
F_c7e1249ffc03eb9ded908c236bd1996d int,
F_2a38a4a9316c49e5a833517c45d31070 int,
F_7647966b7343c29048673252e490f736 int,
F_8613985ec49eb8f757ae6439e879bb2a int,
F_54229abfcfa5649e7003b83dd4755294 int,
F_92cc227532d17e56e07902b254dfad10 int,
F_98dce83da57b0395e163467c9dae521b int,
F_f4b9ec30ad9f68f89b29639786cb62ef int,
F_812b4ba287f5ee0bc9d43bbf5bbe87fb int,
F_26657d5ff9020d2abefe558796b99584 int,
F_e2ef524fbf3d9fe611d5a8e90fefdc9c int,
F_ed3d2c21991e3bef5e069713af9fa6ca int,
F_ac627ab1ccbdb62ec96e702f07f6425b int,
F_f899139df5e1059396431415e770c6dd int,
F_38b3eff8baf56627478ec76a704e9b52 int,
F_ec8956637a99787bd197eacd77acce5e int,
F_6974ce5ac660610b44d9b9fed0ff9548 int,
F_c9e1074f5b3f9fc8ea15d152add07294 int,
F_65b9eea6e1cc6bb9f0cd2a47751a186f int,
F_f0935e4cd5920aa6c7c996a5ee53a70f int,
F_a97da629b098b75c294dffdc3e463904 int,
F_a3c65c2974270fd093ee8a9bf8ae7d0b int,
F_2723d092b63885e0d7c260cc007e8b9d int,
F_5f93f983524def3dca464469d2cf9f3e int,
F_698d51a19d8a121ce581499d7b701668 int,
F_7f6ffaa6bb0b408017b62254211691b5 int,
F_73278a4a86960eeb576a8fd4c9ec6997 int,
F_5fd0b37cd7dbbb00f97ba6ce92bf5add int,
F_2b44928ae11fb9384c4cf38708677c48 int,
F_c45147dee729311ef5b5c3003946c48f int,
F_eb160de1de89d9058fcb0b968dbbbd68 int,
F_5ef059938ba799aaa845e1c2e8a762bd int,
F_07e1cd7dca89a1678042477183b7ac3f int,
F_da4fb5c6e93e74d3df8527599fa62642 int,
F_4c56ff4ce4aaf9573aa5dff913df997a int,
F_a0a080f42e6f13b3a2df133f073095dd int,
F_202cb962ac59075b964b07152d234b70 int,
F_c8ffe9a587b126f152ed3d89a146b445 int,
F_3def184ad8f4755ff269862ea77393dd int,
F_069059b7ef840f0c74a814ec9237b6ec int,
F_ec5decca5ed3d6b8079e2e7e7bacc9f2 int,
F_76dc611d6ebaafc66cc0879c71b5db5c int,
F_d1f491a404d6854880943e5c3cd9ca25 int,
F_9b8619251a19057cff70779273e95aa6 int,
F_1afa34a7f984eeabdbb0a7d494132ee5 int,
F_65ded5353c5ee48d0b7d48c591b8f430 int,
F_9fc3d7152ba9336a670e36d0ed79bc43 int,
F_02522a2b2726fb0a03bb19f2d8d9524d int,
F_7f1de29e6da19d22b51c68001e7e0e54 int,
F_42a0e188f5033bc65bf8d78622277c4e int,
F_3988c7f88ebcb58c6ce932b957b6f332 int,
F_013d407166ec4fa56eb1e1f8cbe183b9 int,
F_e00da03b685a0dd18fb6a08af0923de0 int,
F_1385974ed5904a438616ff7bdb3f7439 int,
F_0f28b5d49b3020afeecd95b4009adf4c int,
F_a8baa56554f96369ab93e4f3bb068c22 int,
F_903ce9225fca3e988c2af215d4e544d3 int,
F_0a09c8844ba8f0936c20bd791130d6b6 int,
F_2b24d495052a8ce66358eb576b8912c8 int,
F_a5e00132373a7031000fd987a3c9f87b int,
F_8d5e957f297893487bd98fa830fa6413 int,
F_47d1e990583c9c67424d369f3414728e int,
F_f2217062e9a397a1dca429e7d70bc6ca int,
F_7ef605fc8dba5425d6965fbd4c8fbe1f int,
F_a8f15eda80c50adb0e71943adc8015cf int,
F_37a749d808e46495a8da1e5352d03cae int,
F_b3e3e393c77e35a4a3f3cbd1e429b5dc int,
F_1d7f7abc18fcb43975065399b0d1e48e int,
F_2a79ea27c279e471f4d180b08d62b00a int,
F_1c9ac0159c94d8d0cbedc973445af2da int,
F_6c4b761a28b734fe93831e3fb400ce87 int,
F_06409663226af2f3114485aa4e0a23b4 int,
F_140f6969d5213fd0ece03148e62e461e int,
F_b73ce398c39f506af761d2277d853a92 int,
F_bd4c9ab730f5513206b999ec0d90d1fb int,
F_82aa4b0af34c2313a562076992e50aa3 int,
F_0777d5c17d4066b82ab86dff8a46af6f int,
F_fa7cdfad1a5aaf8370ebeda47a1ff1c3 int,
F_9766527f2b5d3e95d4a733fcfb77bd7e int,
F_7e7757b1e12abcb736ab9a754ffb617a int,
F_5878a7ab84fb43402106c575658472fa int,
F_006f52e9102a8d3be2fe5614f42ba989 int,
F_3636638817772e42b59d74cff571fbb3 int,
F_149e9677a5989fd342ae44213df68868 int,
F_a4a042cf4fd6bfb47701cbc8a1653ada int,
F_1ff8a7b5dc7a7d1f0ed65aaa29c04b1e int,
F_f7e6c85504ce6e82442c770f7c8606f0 int,
F_bf8229696f7a3bb4700cfddef19fa23f int,
F_82161242827b703e6acf9c726942a1e4 int,
F_38af86134b65d0f10fe33d30dd76442e int,
F_96da2f590cd7246bbde0051047b0d6f7 int,
F_8f85517967795eeef66c225f7883bdcb int,
F_8f53295a73878494e9bc8dd6c3c7104f int,
F_045117b0e0a11a242b9765e79cbf113f int,
F_fc221309746013ac554571fbd180e1c8 int,
F_4c5bde74a8f110656874902f07378009 int,
F_cedebb6e872f539bef8c3f919874e9d7 int,
F_6cdd60ea0045eb7a6ec44c54d29ed402 int,
F_eecca5b6365d9607ee5a9d336962c534 int,
F_9872ed9fc22fc182d371c3e9ed316094 int,
F_31fefc0e570cb3860f2a6d4b38c6490d int,
F_9dcb88e0137649590b755372b040afad int,
F_a2557a7b2e94197ff767970b67041697 int,
F_cfecdb276f634854f3ef915e2e980c31 int,
F_0aa1883c6411f7873cb83dacb17b0afc int,
F_58a2fc6ed39fd083f55d4182bf88826d int,
F_bd686fd640be98efaae0091fa301e613 int,
F_a597e50502f5ff68e3e25b9114205d4a int,
F_0336dcbab05b9d5ad24f4333c7658a0e int,
F_084b6fbb10729ed4da8c3d3f5a3ae7c9 int,
F_85d8ce590ad8981ca2c8286f79f59954 int,
F_0e65972dce68dad4d52d063967f0a705 int,
F_84d9ee44e457ddef7f2c4f25dc8fa865 int,
F_3644a684f98ea8fe223c713b77189a77 int,
F_757b505cfd34c64c85ca5b5690ee5293 int,
F_854d6fae5ee42911677c739ee1734486 int,
F_e2c0be24560d78c5e599c2a9c9d0bbd2 int,
F_274ad4786c3abca69fa097b85867d9a4 int,
F_eae27d77ca20db309e056e3d2dcd7d69 int,
F_7eabe3a1649ffa2b3ff8c02ebfd5659f int,
F_69adc1e107f7f7d035d7baf04342e1ca int,
F_091d584fced301b442654dd8c23b3fc9 int,
F_b1d10e7bafa4421218a51b1e1f1b0ba2 int,
F_6f3ef77ac0e3619e98159e9b6febf557 int,
F_eb163727917cbba1eea208541a643e74 int,
F_1534b76d325a8f591b52d302e7181331 int,
F_979d472a84804b9f647bc185a877a8b5 int,
F_ca46c1b9512a7a8315fa3c5a946e8265 int,
F_3b8a614226a953a8cd9526fca6fe9ba5 int,
F_45fbc6d3e05ebd93369ce542e8f2322d int,
F_63dc7ed1010d3c3b8269faf0ba7491d4 int,
F_e96ed478dab8595a7dbda4cbcbee168f int,
F_c0e190d8267e36708f955d7ab048990d int,
F_ec8ce6abb3e952a85b8551ba726a1227 int,
F_060ad92489947d410d897474079c1477 int,
F_bcbe3365e6ac95ea2c0343a2395834dd int,
F_115f89503138416a242f40fb7d7f338e int,
F_13fe9d84310e77f13a6d184dbf1232f3 int,
F_d1c38a09acc34845c6be3a127a5aacaf int,
F_9cfdf10e8fc047a44b08ed031e1f0ed1 int,
F_705f2172834666788607efbfca35afb3 int,
F_74db120f0a8e5646ef5a30154e9f6deb int,
F_57aeee35c98205091e18d1140e9f38cf int,
F_6da9003b743b65f4c0ccd295cc484e57 int,
F_9b04d152845ec0a378394003c96da594 int,
F_be83ab3ecd0db773eb2dc1b0a17836a1 int,
F_e165421110ba03099a1c0393373c5b43 int,
F_289dff07669d7a23de0ef88d2f7129e7 int,
F_577ef1154f3240ad5b9b413aa7346a1e int,
F_01161aaa0b6d1345dd8fe4e481144d84 int,
F_539fd53b59e3bb12d203f45a912eeaf2 int,
F_ac1dd209cbcc5e5d1c6e28598e8cbbe8 int,
F_555d6702c950ecb729a966504af0a635 int,
F_335f5352088d7d9bf74191e006d8e24c int,
F_f340f1b1f65b6df5b5e3f94d95b11daf int,
F_e4a6222cdb5b34375400904f03d8e6a5 int,
F_cb70ab375662576bd1ac5aaf16b3fca4 int,
F_9188905e74c28e489b44e954ec0b9bca int,
F_0266e33d3f546cb5436a10798e657d97 int,
F_38db3aed920cf82ab059bfccbd02be6a int,
F_3cec07e9ba5f5bb252d13f5f431e4bbb int,
F_621bf66ddb7c962aa0d22ac97d69b793 int,
F_077e29b11be80ab57e1a2ecabb7da330 int,
F_6c9882bbac1c7093bd25041881277658 int,
F_19f3cd308f1455b3fa09a282e0d496f4 int,
F_03c6b06952c750899bb03d998e631860 int,
F_c24cd76e1ce41366a4bbe8a49b02a028 int,
F_c52f1bd66cc19d05628bd8bf27af3ad6 int,
F_fe131d7f5a6b38b23cc967316c13dae2 int,
F_f718499c1c8cef6730f9fd03c8125cab int,
F_d96409bf894217686ba124d7356686c9 int,
F_502e4a16930e414107ee22b6198c578f int,
F_cfa0860e83a4c3a763a7e62d825349f7 int,
F_a4f23670e1833f3fdb077ca70bbd5d66 int,
F_b1a59b315fc9a3002ce38bbe070ec3f5 int,
F_36660e59856b4de58a219bcf4e27eba3 int,
F_8c19f571e251e61cb8dd3612f26d5ecf int,
F_d6baf65e0b240ce177cf70da146c8dc8 int,
F_e56954b4f6347e897f954495eab16a88 int,
F_f7664060cc52bc6f3d620bcedc94a4b6 int,
F_eda80a3d5b344bc40f3bc04f65b7a357 int,
F_8f121ce07d74717e0b1f21d122e04521 int,
F_06138bc5af6023646ede0e1f7c1eac75 int,
F_39059724f73a9969845dfe4146c5660e int,
F_7f100b7b36092fb9b06dfb4fac360931 int,
F_7a614fd06c325499f1680b9896beedeb int,
F_4734ba6f3de83d861c3176a6273cac6d int,
F_d947bf06a885db0d477d707121934ff8 int,
F_63923f49e5241343aa7acb6a06a751e7 int,
F_db8e1af0cb3aca1ae2d0018624204529 int,
F_20f07591c6fcb220ffe637cda29bb3f6 int,
F_07cdfd23373b17c6b337251c22b7ea57 int,
F_d395771085aab05244a4fb8fd91bf4ee int,
F_92c8c96e4c37100777c7190b76d28233 int,
F_e3796ae838835da0b6f6ea37bcf8bcb7 int,
F_6a9aeddfc689c1d0e3b9ccc3ab651bc5 int,
F_0f49c89d1e7298bb9930789c8ed59d48 int,
F_46ba9f2a6976570b0353203ec4474217 int,
F_0e01938fc48a2cfb5f2217fbfb00722d int,
F_16a5cdae362b8d27a1d8f8c7b78b4330 int,
F_918317b57931b6b7a7d29490fe5ec9f9 int,
F_48aedb8880cab8c45637abc7493ecddd int,
F_839ab46820b524afda05122893c2fe8e int,
F_f90f2aca5c640289d0a29417bcb63a37 int,
F_9c838d2e45b2ad1094d42f4ef36764f6 int,
F_1700002963a49da13542e0726b7bb758 int,
F_53c3bce66e43be4f209556518c2fcb54 int,
F_6883966fd8f918a4aa29be29d2c386fb int,
F_49182f81e6a13cf5eaa496d51fea6406 int,
F_d296c101daa88a51f6ca8cfc1ac79b50 int,
F_9fd81843ad7f202f26c1a174c7357585 int,
F_26e359e83860db1d11b6acca57d8ea88 int,
F_ef0d3930a7b6c95bd2b32ed45989c61f int,
F_94f6d7e04a4d452035300f18b984988c int,
F_34ed066df378efacc9b924ec161e7639 int,
F_577bcc914f9e55d5e4e4f82f9f00e7d4 int,
F_11b9842e0a271ff252c1903e7132cd68 int,
F_37bc2f75bf1bcfe8450a1a41c200364c int,
F_496e05e1aea0a9c4655800e8a7b9ea28 int,
F_b2eb7349035754953b57a32e2841bda5 int,
F_8e98d81f8217304975ccb23337bb5761 int,
F_a8c88a0055f636e4a163a5e3d16adab7 int,
F_eddea82ad2755b24c4e168c5fc2ebd40 int,
F_06eb61b839a0cefee4967c67ccb099dc int,
F_9dfcd5e558dfa04aaf37f137a1d9d3e5 int,
F_950a4152c2b4aa3ad78bdd6b366cc179 int,
F_158f3069a435b314a80bdcb024f8e422 int,
F_758874998f5bd0c393da094e1967a72b int,
F_ad13a2a07ca4b7642959dc0c4c740ab6 int,
F_3fe94a002317b5f9259f82690aeea4cd int,
F_5b8add2a5d98b1a652ea7fd72d942dac int,
F_432aca3a1e345e339f35a30c8f65edce int,
F_8d3bba7425e7c98c50f52ca1b52d3735 int,
F_320722549d1751cf3f247855f937b982 int,
F_caf1a3dfb505ffed0d024130f58c5cfa int,
F_5737c6ec2e0716f3d8a7a5c4e0de0d9a int,
F_bc6dc48b743dc5d013b1abaebd2faed2 int,
F_f2fc990265c712c49d51a18a32b39f0c int,
F_89f0fd5c927d466d6ec9a21b9ac34ffa int,
F_a666587afda6e89aec274a3657558a27 int,
F_b83aac23b9528732c23cc7352950e880 int,
F_cd00692c3bfe59267d5ecfac5310286c int,
F_6faa8040da20ef399b63a72d0e4ab575 int,
F_fe73f687e5bc5280214e0486b273a5f9 int);
insert into t1 (F_8d3bba7425e7c98c50f52ca1b52d3735) values (1);

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
1127 1128
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
1129 1130 1131 1132 1133
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
1134 1135
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
1136
CREATE TABLE `t1` (
1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466
  `F_c4ca4238a0b923820dcc509a6f75849b` int(11) DEFAULT NULL,
  `F_c81e728d9d4c2f636f067f89cc14862c` int(11) DEFAULT NULL,
  `F_eccbc87e4b5ce2fe28308fd9f2a7baf3` int(11) DEFAULT NULL,
  `F_a87ff679a2f3e71d9181a67b7542122c` int(11) DEFAULT NULL,
  `F_e4da3b7fbbce2345d7772b0674a318d5` int(11) DEFAULT NULL,
  `F_1679091c5a880faf6fb5e6087eb1b2dc` int(11) DEFAULT NULL,
  `F_8f14e45fceea167a5a36dedd4bea2543` int(11) DEFAULT NULL,
  `F_c9f0f895fb98ab9159f51fd0297e236d` int(11) DEFAULT NULL,
  `F_45c48cce2e2d7fbdea1afc51c7c6ad26` int(11) DEFAULT NULL,
  `F_d3d9446802a44259755d38e6d163e820` int(11) DEFAULT NULL,
  `F_6512bd43d9caa6e02c990b0a82652dca` int(11) DEFAULT NULL,
  `F_c20ad4d76fe97759aa27a0c99bff6710` int(11) DEFAULT NULL,
  `F_c51ce410c124a10e0db5e4b97fc2af39` int(11) DEFAULT NULL,
  `F_aab3238922bcc25a6f606eb525ffdc56` int(11) DEFAULT NULL,
  `F_9bf31c7ff062936a96d3c8bd1f8f2ff3` int(11) DEFAULT NULL,
  `F_c74d97b01eae257e44aa9d5bade97baf` int(11) DEFAULT NULL,
  `F_70efdf2ec9b086079795c442636b55fb` int(11) DEFAULT NULL,
  `F_6f4922f45568161a8cdf4ad2299f6d23` int(11) DEFAULT NULL,
  `F_1f0e3dad99908345f7439f8ffabdffc4` int(11) DEFAULT NULL,
  `F_98f13708210194c475687be6106a3b84` int(11) DEFAULT NULL,
  `F_3c59dc048e8850243be8079a5c74d079` int(11) DEFAULT NULL,
  `F_b6d767d2f8ed5d21a44b0e5886680cb9` int(11) DEFAULT NULL,
  `F_37693cfc748049e45d87b8c7d8b9aacd` int(11) DEFAULT NULL,
  `F_1ff1de774005f8da13f42943881c655f` int(11) DEFAULT NULL,
  `F_8e296a067a37563370ded05f5a3bf3ec` int(11) DEFAULT NULL,
  `F_4e732ced3463d06de0ca9a15b6153677` int(11) DEFAULT NULL,
  `F_02e74f10e0327ad868d138f2b4fdd6f0` int(11) DEFAULT NULL,
  `F_33e75ff09dd601bbe69f351039152189` int(11) DEFAULT NULL,
  `F_6ea9ab1baa0efb9e19094440c317e21b` int(11) DEFAULT NULL,
  `F_34173cb38f07f89ddbebc2ac9128303f` int(11) DEFAULT NULL,
  `F_c16a5320fa475530d9583c34fd356ef5` int(11) DEFAULT NULL,
  `F_6364d3f0f495b6ab9dcf8d3b5c6e0b01` int(11) DEFAULT NULL,
  `F_182be0c5cdcd5072bb1864cdee4d3d6e` int(11) DEFAULT NULL,
  `F_e369853df766fa44e1ed0ff613f563bd` int(11) DEFAULT NULL,
  `F_1c383cd30b7c298ab50293adfecb7b18` int(11) DEFAULT NULL,
  `F_19ca14e7ea6328a42e0eb13d585e4c22` int(11) DEFAULT NULL,
  `F_a5bfc9e07964f8dddeb95fc584cd965d` int(11) DEFAULT NULL,
  `F_a5771bce93e200c36f7cd9dfd0e5deaa` int(11) DEFAULT NULL,
  `F_d67d8ab4f4c10bf22aa353e27879133c` int(11) DEFAULT NULL,
  `F_d645920e395fedad7bbbed0eca3fe2e0` int(11) DEFAULT NULL,
  `F_3416a75f4cea9109507cacd8e2f2aefc` int(11) DEFAULT NULL,
  `F_a1d0c6e83f027327d8461063f4ac58a6` int(11) DEFAULT NULL,
  `F_17e62166fc8586dfa4d1bc0e1742c08b` int(11) DEFAULT NULL,
  `F_f7177163c833dff4b38fc8d2872f1ec6` int(11) DEFAULT NULL,
  `F_6c8349cc7260ae62e3b1396831a8398f` int(11) DEFAULT NULL,
  `F_d9d4f495e875a2e075a1a4a6e1b9770f` int(11) DEFAULT NULL,
  `F_67c6a1e7ce56d3d6fa748ab6d9af3fd7` int(11) DEFAULT NULL,
  `F_642e92efb79421734881b53e1e1b18b6` int(11) DEFAULT NULL,
  `F_f457c545a9ded88f18ecee47145a72c0` int(11) DEFAULT NULL,
  `F_c0c7c76d30bd3dcaefc96f40275bdc0a` int(11) DEFAULT NULL,
  `F_2838023a778dfaecdc212708f721b788` int(11) DEFAULT NULL,
  `F_9a1158154dfa42caddbd0694a4e9bdc8` int(11) DEFAULT NULL,
  `F_d82c8d1619ad8176d665453cfb2e55f0` int(11) DEFAULT NULL,
  `F_a684eceee76fc522773286a895bc8436` int(11) DEFAULT NULL,
  `F_b53b3a3d6ab90ce0268229151c9bde11` int(11) DEFAULT NULL,
  `F_9f61408e3afb633e50cdf1b20de6f466` int(11) DEFAULT NULL,
  `F_72b32a1f754ba1c09b3695e0cb6cde7f` int(11) DEFAULT NULL,
  `F_66f041e16a60928b05a7e228a89c3799` int(11) DEFAULT NULL,
  `F_093f65e080a295f8076b1c5722a46aa2` int(11) DEFAULT NULL,
  `F_072b030ba126b2f4b2374f342be9ed44` int(11) DEFAULT NULL,
  `F_7f39f8317fbdb1988ef4c628eba02591` int(11) DEFAULT NULL,
  `F_44f683a84163b3523afe57c2e008bc8c` int(11) DEFAULT NULL,
  `F_03afdbd66e7929b125f8597834fa83a4` int(11) DEFAULT NULL,
  `F_ea5d2f1c4608232e07d3aa3d998e5135` int(11) DEFAULT NULL,
  `F_fc490ca45c00b1249bbe3554a4fdf6fb` int(11) DEFAULT NULL,
  `F_3295c76acbf4caaed33c36b1b5fc2cb1` int(11) DEFAULT NULL,
  `F_735b90b4568125ed6c3f678819b6e058` int(11) DEFAULT NULL,
  `F_a3f390d88e4c41f2747bfa2f1b5f87db` int(11) DEFAULT NULL,
  `F_14bfa6bb14875e45bba028a21ed38046` int(11) DEFAULT NULL,
  `F_7cbbc409ec990f19c78c75bd1e06f215` int(11) DEFAULT NULL,
  `F_e2c420d928d4bf8ce0ff2ec19b371514` int(11) DEFAULT NULL,
  `F_32bb90e8976aab5298d5da10fe66f21d` int(11) DEFAULT NULL,
  `F_d2ddea18f00665ce8623e36bd4e3c7c5` int(11) DEFAULT NULL,
  `F_ad61ab143223efbc24c7d2583be69251` int(11) DEFAULT NULL,
  `F_d09bf41544a3365a46c9077ebb5e35c3` int(11) DEFAULT NULL,
  `F_fbd7939d674997cdb4692d34de8633c4` int(11) DEFAULT NULL,
  `F_28dd2c7955ce926456240b2ff0100bde` int(11) DEFAULT NULL,
  `F_35f4a8d465e6e1edc05f3d8ab658c551` int(11) DEFAULT NULL,
  `F_d1fe173d08e959397adf34b1d77e88d7` int(11) DEFAULT NULL,
  `F_f033ab37c30201f73f142449d037028d` int(11) DEFAULT NULL,
  `F_43ec517d68b6edd3015b3edc9a11367b` int(11) DEFAULT NULL,
  `F_9778d5d219c5080b9a6a17bef029331c` int(11) DEFAULT NULL,
  `F_fe9fc289c3ff0af142b6d3bead98a923` int(11) DEFAULT NULL,
  `F_68d30a9594728bc39aa24be94b319d21` int(11) DEFAULT NULL,
  `F_3ef815416f775098fe977004015c6193` int(11) DEFAULT NULL,
  `F_93db85ed909c13838ff95ccfa94cebd9` int(11) DEFAULT NULL,
  `F_c7e1249ffc03eb9ded908c236bd1996d` int(11) DEFAULT NULL,
  `F_2a38a4a9316c49e5a833517c45d31070` int(11) DEFAULT NULL,
  `F_7647966b7343c29048673252e490f736` int(11) DEFAULT NULL,
  `F_8613985ec49eb8f757ae6439e879bb2a` int(11) DEFAULT NULL,
  `F_54229abfcfa5649e7003b83dd4755294` int(11) DEFAULT NULL,
  `F_92cc227532d17e56e07902b254dfad10` int(11) DEFAULT NULL,
  `F_98dce83da57b0395e163467c9dae521b` int(11) DEFAULT NULL,
  `F_f4b9ec30ad9f68f89b29639786cb62ef` int(11) DEFAULT NULL,
  `F_812b4ba287f5ee0bc9d43bbf5bbe87fb` int(11) DEFAULT NULL,
  `F_26657d5ff9020d2abefe558796b99584` int(11) DEFAULT NULL,
  `F_e2ef524fbf3d9fe611d5a8e90fefdc9c` int(11) DEFAULT NULL,
  `F_ed3d2c21991e3bef5e069713af9fa6ca` int(11) DEFAULT NULL,
  `F_ac627ab1ccbdb62ec96e702f07f6425b` int(11) DEFAULT NULL,
  `F_f899139df5e1059396431415e770c6dd` int(11) DEFAULT NULL,
  `F_38b3eff8baf56627478ec76a704e9b52` int(11) DEFAULT NULL,
  `F_ec8956637a99787bd197eacd77acce5e` int(11) DEFAULT NULL,
  `F_6974ce5ac660610b44d9b9fed0ff9548` int(11) DEFAULT NULL,
  `F_c9e1074f5b3f9fc8ea15d152add07294` int(11) DEFAULT NULL,
  `F_65b9eea6e1cc6bb9f0cd2a47751a186f` int(11) DEFAULT NULL,
  `F_f0935e4cd5920aa6c7c996a5ee53a70f` int(11) DEFAULT NULL,
  `F_a97da629b098b75c294dffdc3e463904` int(11) DEFAULT NULL,
  `F_a3c65c2974270fd093ee8a9bf8ae7d0b` int(11) DEFAULT NULL,
  `F_2723d092b63885e0d7c260cc007e8b9d` int(11) DEFAULT NULL,
  `F_5f93f983524def3dca464469d2cf9f3e` int(11) DEFAULT NULL,
  `F_698d51a19d8a121ce581499d7b701668` int(11) DEFAULT NULL,
  `F_7f6ffaa6bb0b408017b62254211691b5` int(11) DEFAULT NULL,
  `F_73278a4a86960eeb576a8fd4c9ec6997` int(11) DEFAULT NULL,
  `F_5fd0b37cd7dbbb00f97ba6ce92bf5add` int(11) DEFAULT NULL,
  `F_2b44928ae11fb9384c4cf38708677c48` int(11) DEFAULT NULL,
  `F_c45147dee729311ef5b5c3003946c48f` int(11) DEFAULT NULL,
  `F_eb160de1de89d9058fcb0b968dbbbd68` int(11) DEFAULT NULL,
  `F_5ef059938ba799aaa845e1c2e8a762bd` int(11) DEFAULT NULL,
  `F_07e1cd7dca89a1678042477183b7ac3f` int(11) DEFAULT NULL,
  `F_da4fb5c6e93e74d3df8527599fa62642` int(11) DEFAULT NULL,
  `F_4c56ff4ce4aaf9573aa5dff913df997a` int(11) DEFAULT NULL,
  `F_a0a080f42e6f13b3a2df133f073095dd` int(11) DEFAULT NULL,
  `F_202cb962ac59075b964b07152d234b70` int(11) DEFAULT NULL,
  `F_c8ffe9a587b126f152ed3d89a146b445` int(11) DEFAULT NULL,
  `F_3def184ad8f4755ff269862ea77393dd` int(11) DEFAULT NULL,
  `F_069059b7ef840f0c74a814ec9237b6ec` int(11) DEFAULT NULL,
  `F_ec5decca5ed3d6b8079e2e7e7bacc9f2` int(11) DEFAULT NULL,
  `F_76dc611d6ebaafc66cc0879c71b5db5c` int(11) DEFAULT NULL,
  `F_d1f491a404d6854880943e5c3cd9ca25` int(11) DEFAULT NULL,
  `F_9b8619251a19057cff70779273e95aa6` int(11) DEFAULT NULL,
  `F_1afa34a7f984eeabdbb0a7d494132ee5` int(11) DEFAULT NULL,
  `F_65ded5353c5ee48d0b7d48c591b8f430` int(11) DEFAULT NULL,
  `F_9fc3d7152ba9336a670e36d0ed79bc43` int(11) DEFAULT NULL,
  `F_02522a2b2726fb0a03bb19f2d8d9524d` int(11) DEFAULT NULL,
  `F_7f1de29e6da19d22b51c68001e7e0e54` int(11) DEFAULT NULL,
  `F_42a0e188f5033bc65bf8d78622277c4e` int(11) DEFAULT NULL,
  `F_3988c7f88ebcb58c6ce932b957b6f332` int(11) DEFAULT NULL,
  `F_013d407166ec4fa56eb1e1f8cbe183b9` int(11) DEFAULT NULL,
  `F_e00da03b685a0dd18fb6a08af0923de0` int(11) DEFAULT NULL,
  `F_1385974ed5904a438616ff7bdb3f7439` int(11) DEFAULT NULL,
  `F_0f28b5d49b3020afeecd95b4009adf4c` int(11) DEFAULT NULL,
  `F_a8baa56554f96369ab93e4f3bb068c22` int(11) DEFAULT NULL,
  `F_903ce9225fca3e988c2af215d4e544d3` int(11) DEFAULT NULL,
  `F_0a09c8844ba8f0936c20bd791130d6b6` int(11) DEFAULT NULL,
  `F_2b24d495052a8ce66358eb576b8912c8` int(11) DEFAULT NULL,
  `F_a5e00132373a7031000fd987a3c9f87b` int(11) DEFAULT NULL,
  `F_8d5e957f297893487bd98fa830fa6413` int(11) DEFAULT NULL,
  `F_47d1e990583c9c67424d369f3414728e` int(11) DEFAULT NULL,
  `F_f2217062e9a397a1dca429e7d70bc6ca` int(11) DEFAULT NULL,
  `F_7ef605fc8dba5425d6965fbd4c8fbe1f` int(11) DEFAULT NULL,
  `F_a8f15eda80c50adb0e71943adc8015cf` int(11) DEFAULT NULL,
  `F_37a749d808e46495a8da1e5352d03cae` int(11) DEFAULT NULL,
  `F_b3e3e393c77e35a4a3f3cbd1e429b5dc` int(11) DEFAULT NULL,
  `F_1d7f7abc18fcb43975065399b0d1e48e` int(11) DEFAULT NULL,
  `F_2a79ea27c279e471f4d180b08d62b00a` int(11) DEFAULT NULL,
  `F_1c9ac0159c94d8d0cbedc973445af2da` int(11) DEFAULT NULL,
  `F_6c4b761a28b734fe93831e3fb400ce87` int(11) DEFAULT NULL,
  `F_06409663226af2f3114485aa4e0a23b4` int(11) DEFAULT NULL,
  `F_140f6969d5213fd0ece03148e62e461e` int(11) DEFAULT NULL,
  `F_b73ce398c39f506af761d2277d853a92` int(11) DEFAULT NULL,
  `F_bd4c9ab730f5513206b999ec0d90d1fb` int(11) DEFAULT NULL,
  `F_82aa4b0af34c2313a562076992e50aa3` int(11) DEFAULT NULL,
  `F_0777d5c17d4066b82ab86dff8a46af6f` int(11) DEFAULT NULL,
  `F_fa7cdfad1a5aaf8370ebeda47a1ff1c3` int(11) DEFAULT NULL,
  `F_9766527f2b5d3e95d4a733fcfb77bd7e` int(11) DEFAULT NULL,
  `F_7e7757b1e12abcb736ab9a754ffb617a` int(11) DEFAULT NULL,
  `F_5878a7ab84fb43402106c575658472fa` int(11) DEFAULT NULL,
  `F_006f52e9102a8d3be2fe5614f42ba989` int(11) DEFAULT NULL,
  `F_3636638817772e42b59d74cff571fbb3` int(11) DEFAULT NULL,
  `F_149e9677a5989fd342ae44213df68868` int(11) DEFAULT NULL,
  `F_a4a042cf4fd6bfb47701cbc8a1653ada` int(11) DEFAULT NULL,
  `F_1ff8a7b5dc7a7d1f0ed65aaa29c04b1e` int(11) DEFAULT NULL,
  `F_f7e6c85504ce6e82442c770f7c8606f0` int(11) DEFAULT NULL,
  `F_bf8229696f7a3bb4700cfddef19fa23f` int(11) DEFAULT NULL,
  `F_82161242827b703e6acf9c726942a1e4` int(11) DEFAULT NULL,
  `F_38af86134b65d0f10fe33d30dd76442e` int(11) DEFAULT NULL,
  `F_96da2f590cd7246bbde0051047b0d6f7` int(11) DEFAULT NULL,
  `F_8f85517967795eeef66c225f7883bdcb` int(11) DEFAULT NULL,
  `F_8f53295a73878494e9bc8dd6c3c7104f` int(11) DEFAULT NULL,
  `F_045117b0e0a11a242b9765e79cbf113f` int(11) DEFAULT NULL,
  `F_fc221309746013ac554571fbd180e1c8` int(11) DEFAULT NULL,
  `F_4c5bde74a8f110656874902f07378009` int(11) DEFAULT NULL,
  `F_cedebb6e872f539bef8c3f919874e9d7` int(11) DEFAULT NULL,
  `F_6cdd60ea0045eb7a6ec44c54d29ed402` int(11) DEFAULT NULL,
  `F_eecca5b6365d9607ee5a9d336962c534` int(11) DEFAULT NULL,
  `F_9872ed9fc22fc182d371c3e9ed316094` int(11) DEFAULT NULL,
  `F_31fefc0e570cb3860f2a6d4b38c6490d` int(11) DEFAULT NULL,
  `F_9dcb88e0137649590b755372b040afad` int(11) DEFAULT NULL,
  `F_a2557a7b2e94197ff767970b67041697` int(11) DEFAULT NULL,
  `F_cfecdb276f634854f3ef915e2e980c31` int(11) DEFAULT NULL,
  `F_0aa1883c6411f7873cb83dacb17b0afc` int(11) DEFAULT NULL,
  `F_58a2fc6ed39fd083f55d4182bf88826d` int(11) DEFAULT NULL,
  `F_bd686fd640be98efaae0091fa301e613` int(11) DEFAULT NULL,
  `F_a597e50502f5ff68e3e25b9114205d4a` int(11) DEFAULT NULL,
  `F_0336dcbab05b9d5ad24f4333c7658a0e` int(11) DEFAULT NULL,
  `F_084b6fbb10729ed4da8c3d3f5a3ae7c9` int(11) DEFAULT NULL,
  `F_85d8ce590ad8981ca2c8286f79f59954` int(11) DEFAULT NULL,
  `F_0e65972dce68dad4d52d063967f0a705` int(11) DEFAULT NULL,
  `F_84d9ee44e457ddef7f2c4f25dc8fa865` int(11) DEFAULT NULL,
  `F_3644a684f98ea8fe223c713b77189a77` int(11) DEFAULT NULL,
  `F_757b505cfd34c64c85ca5b5690ee5293` int(11) DEFAULT NULL,
  `F_854d6fae5ee42911677c739ee1734486` int(11) DEFAULT NULL,
  `F_e2c0be24560d78c5e599c2a9c9d0bbd2` int(11) DEFAULT NULL,
  `F_274ad4786c3abca69fa097b85867d9a4` int(11) DEFAULT NULL,
  `F_eae27d77ca20db309e056e3d2dcd7d69` int(11) DEFAULT NULL,
  `F_7eabe3a1649ffa2b3ff8c02ebfd5659f` int(11) DEFAULT NULL,
  `F_69adc1e107f7f7d035d7baf04342e1ca` int(11) DEFAULT NULL,
  `F_091d584fced301b442654dd8c23b3fc9` int(11) DEFAULT NULL,
  `F_b1d10e7bafa4421218a51b1e1f1b0ba2` int(11) DEFAULT NULL,
  `F_6f3ef77ac0e3619e98159e9b6febf557` int(11) DEFAULT NULL,
  `F_eb163727917cbba1eea208541a643e74` int(11) DEFAULT NULL,
  `F_1534b76d325a8f591b52d302e7181331` int(11) DEFAULT NULL,
  `F_979d472a84804b9f647bc185a877a8b5` int(11) DEFAULT NULL,
  `F_ca46c1b9512a7a8315fa3c5a946e8265` int(11) DEFAULT NULL,
  `F_3b8a614226a953a8cd9526fca6fe9ba5` int(11) DEFAULT NULL,
  `F_45fbc6d3e05ebd93369ce542e8f2322d` int(11) DEFAULT NULL,
  `F_63dc7ed1010d3c3b8269faf0ba7491d4` int(11) DEFAULT NULL,
  `F_e96ed478dab8595a7dbda4cbcbee168f` int(11) DEFAULT NULL,
  `F_c0e190d8267e36708f955d7ab048990d` int(11) DEFAULT NULL,
  `F_ec8ce6abb3e952a85b8551ba726a1227` int(11) DEFAULT NULL,
  `F_060ad92489947d410d897474079c1477` int(11) DEFAULT NULL,
  `F_bcbe3365e6ac95ea2c0343a2395834dd` int(11) DEFAULT NULL,
  `F_115f89503138416a242f40fb7d7f338e` int(11) DEFAULT NULL,
  `F_13fe9d84310e77f13a6d184dbf1232f3` int(11) DEFAULT NULL,
  `F_d1c38a09acc34845c6be3a127a5aacaf` int(11) DEFAULT NULL,
  `F_9cfdf10e8fc047a44b08ed031e1f0ed1` int(11) DEFAULT NULL,
  `F_705f2172834666788607efbfca35afb3` int(11) DEFAULT NULL,
  `F_74db120f0a8e5646ef5a30154e9f6deb` int(11) DEFAULT NULL,
  `F_57aeee35c98205091e18d1140e9f38cf` int(11) DEFAULT NULL,
  `F_6da9003b743b65f4c0ccd295cc484e57` int(11) DEFAULT NULL,
  `F_9b04d152845ec0a378394003c96da594` int(11) DEFAULT NULL,
  `F_be83ab3ecd0db773eb2dc1b0a17836a1` int(11) DEFAULT NULL,
  `F_e165421110ba03099a1c0393373c5b43` int(11) DEFAULT NULL,
  `F_289dff07669d7a23de0ef88d2f7129e7` int(11) DEFAULT NULL,
  `F_577ef1154f3240ad5b9b413aa7346a1e` int(11) DEFAULT NULL,
  `F_01161aaa0b6d1345dd8fe4e481144d84` int(11) DEFAULT NULL,
  `F_539fd53b59e3bb12d203f45a912eeaf2` int(11) DEFAULT NULL,
  `F_ac1dd209cbcc5e5d1c6e28598e8cbbe8` int(11) DEFAULT NULL,
  `F_555d6702c950ecb729a966504af0a635` int(11) DEFAULT NULL,
  `F_335f5352088d7d9bf74191e006d8e24c` int(11) DEFAULT NULL,
  `F_f340f1b1f65b6df5b5e3f94d95b11daf` int(11) DEFAULT NULL,
  `F_e4a6222cdb5b34375400904f03d8e6a5` int(11) DEFAULT NULL,
  `F_cb70ab375662576bd1ac5aaf16b3fca4` int(11) DEFAULT NULL,
  `F_9188905e74c28e489b44e954ec0b9bca` int(11) DEFAULT NULL,
  `F_0266e33d3f546cb5436a10798e657d97` int(11) DEFAULT NULL,
  `F_38db3aed920cf82ab059bfccbd02be6a` int(11) DEFAULT NULL,
  `F_3cec07e9ba5f5bb252d13f5f431e4bbb` int(11) DEFAULT NULL,
  `F_621bf66ddb7c962aa0d22ac97d69b793` int(11) DEFAULT NULL,
  `F_077e29b11be80ab57e1a2ecabb7da330` int(11) DEFAULT NULL,
  `F_6c9882bbac1c7093bd25041881277658` int(11) DEFAULT NULL,
  `F_19f3cd308f1455b3fa09a282e0d496f4` int(11) DEFAULT NULL,
  `F_03c6b06952c750899bb03d998e631860` int(11) DEFAULT NULL,
  `F_c24cd76e1ce41366a4bbe8a49b02a028` int(11) DEFAULT NULL,
  `F_c52f1bd66cc19d05628bd8bf27af3ad6` int(11) DEFAULT NULL,
  `F_fe131d7f5a6b38b23cc967316c13dae2` int(11) DEFAULT NULL,
  `F_f718499c1c8cef6730f9fd03c8125cab` int(11) DEFAULT NULL,
  `F_d96409bf894217686ba124d7356686c9` int(11) DEFAULT NULL,
  `F_502e4a16930e414107ee22b6198c578f` int(11) DEFAULT NULL,
  `F_cfa0860e83a4c3a763a7e62d825349f7` int(11) DEFAULT NULL,
  `F_a4f23670e1833f3fdb077ca70bbd5d66` int(11) DEFAULT NULL,
  `F_b1a59b315fc9a3002ce38bbe070ec3f5` int(11) DEFAULT NULL,
  `F_36660e59856b4de58a219bcf4e27eba3` int(11) DEFAULT NULL,
  `F_8c19f571e251e61cb8dd3612f26d5ecf` int(11) DEFAULT NULL,
  `F_d6baf65e0b240ce177cf70da146c8dc8` int(11) DEFAULT NULL,
  `F_e56954b4f6347e897f954495eab16a88` int(11) DEFAULT NULL,
  `F_f7664060cc52bc6f3d620bcedc94a4b6` int(11) DEFAULT NULL,
  `F_eda80a3d5b344bc40f3bc04f65b7a357` int(11) DEFAULT NULL,
  `F_8f121ce07d74717e0b1f21d122e04521` int(11) DEFAULT NULL,
  `F_06138bc5af6023646ede0e1f7c1eac75` int(11) DEFAULT NULL,
  `F_39059724f73a9969845dfe4146c5660e` int(11) DEFAULT NULL,
  `F_7f100b7b36092fb9b06dfb4fac360931` int(11) DEFAULT NULL,
  `F_7a614fd06c325499f1680b9896beedeb` int(11) DEFAULT NULL,
  `F_4734ba6f3de83d861c3176a6273cac6d` int(11) DEFAULT NULL,
  `F_d947bf06a885db0d477d707121934ff8` int(11) DEFAULT NULL,
  `F_63923f49e5241343aa7acb6a06a751e7` int(11) DEFAULT NULL,
  `F_db8e1af0cb3aca1ae2d0018624204529` int(11) DEFAULT NULL,
  `F_20f07591c6fcb220ffe637cda29bb3f6` int(11) DEFAULT NULL,
  `F_07cdfd23373b17c6b337251c22b7ea57` int(11) DEFAULT NULL,
  `F_d395771085aab05244a4fb8fd91bf4ee` int(11) DEFAULT NULL,
  `F_92c8c96e4c37100777c7190b76d28233` int(11) DEFAULT NULL,
  `F_e3796ae838835da0b6f6ea37bcf8bcb7` int(11) DEFAULT NULL,
  `F_6a9aeddfc689c1d0e3b9ccc3ab651bc5` int(11) DEFAULT NULL,
  `F_0f49c89d1e7298bb9930789c8ed59d48` int(11) DEFAULT NULL,
  `F_46ba9f2a6976570b0353203ec4474217` int(11) DEFAULT NULL,
  `F_0e01938fc48a2cfb5f2217fbfb00722d` int(11) DEFAULT NULL,
  `F_16a5cdae362b8d27a1d8f8c7b78b4330` int(11) DEFAULT NULL,
  `F_918317b57931b6b7a7d29490fe5ec9f9` int(11) DEFAULT NULL,
  `F_48aedb8880cab8c45637abc7493ecddd` int(11) DEFAULT NULL,
  `F_839ab46820b524afda05122893c2fe8e` int(11) DEFAULT NULL,
  `F_f90f2aca5c640289d0a29417bcb63a37` int(11) DEFAULT NULL,
  `F_9c838d2e45b2ad1094d42f4ef36764f6` int(11) DEFAULT NULL,
  `F_1700002963a49da13542e0726b7bb758` int(11) DEFAULT NULL,
  `F_53c3bce66e43be4f209556518c2fcb54` int(11) DEFAULT NULL,
  `F_6883966fd8f918a4aa29be29d2c386fb` int(11) DEFAULT NULL,
  `F_49182f81e6a13cf5eaa496d51fea6406` int(11) DEFAULT NULL,
  `F_d296c101daa88a51f6ca8cfc1ac79b50` int(11) DEFAULT NULL,
  `F_9fd81843ad7f202f26c1a174c7357585` int(11) DEFAULT NULL,
  `F_26e359e83860db1d11b6acca57d8ea88` int(11) DEFAULT NULL,
  `F_ef0d3930a7b6c95bd2b32ed45989c61f` int(11) DEFAULT NULL,
  `F_94f6d7e04a4d452035300f18b984988c` int(11) DEFAULT NULL,
  `F_34ed066df378efacc9b924ec161e7639` int(11) DEFAULT NULL,
  `F_577bcc914f9e55d5e4e4f82f9f00e7d4` int(11) DEFAULT NULL,
  `F_11b9842e0a271ff252c1903e7132cd68` int(11) DEFAULT NULL,
  `F_37bc2f75bf1bcfe8450a1a41c200364c` int(11) DEFAULT NULL,
  `F_496e05e1aea0a9c4655800e8a7b9ea28` int(11) DEFAULT NULL,
  `F_b2eb7349035754953b57a32e2841bda5` int(11) DEFAULT NULL,
  `F_8e98d81f8217304975ccb23337bb5761` int(11) DEFAULT NULL,
  `F_a8c88a0055f636e4a163a5e3d16adab7` int(11) DEFAULT NULL,
  `F_eddea82ad2755b24c4e168c5fc2ebd40` int(11) DEFAULT NULL,
  `F_06eb61b839a0cefee4967c67ccb099dc` int(11) DEFAULT NULL,
  `F_9dfcd5e558dfa04aaf37f137a1d9d3e5` int(11) DEFAULT NULL,
  `F_950a4152c2b4aa3ad78bdd6b366cc179` int(11) DEFAULT NULL,
  `F_158f3069a435b314a80bdcb024f8e422` int(11) DEFAULT NULL,
  `F_758874998f5bd0c393da094e1967a72b` int(11) DEFAULT NULL,
  `F_ad13a2a07ca4b7642959dc0c4c740ab6` int(11) DEFAULT NULL,
  `F_3fe94a002317b5f9259f82690aeea4cd` int(11) DEFAULT NULL,
  `F_5b8add2a5d98b1a652ea7fd72d942dac` int(11) DEFAULT NULL,
  `F_432aca3a1e345e339f35a30c8f65edce` int(11) DEFAULT NULL,
  `F_8d3bba7425e7c98c50f52ca1b52d3735` int(11) DEFAULT NULL,
  `F_320722549d1751cf3f247855f937b982` int(11) DEFAULT NULL,
  `F_caf1a3dfb505ffed0d024130f58c5cfa` int(11) DEFAULT NULL,
  `F_5737c6ec2e0716f3d8a7a5c4e0de0d9a` int(11) DEFAULT NULL,
  `F_bc6dc48b743dc5d013b1abaebd2faed2` int(11) DEFAULT NULL,
  `F_f2fc990265c712c49d51a18a32b39f0c` int(11) DEFAULT NULL,
  `F_89f0fd5c927d466d6ec9a21b9ac34ffa` int(11) DEFAULT NULL,
  `F_a666587afda6e89aec274a3657558a27` int(11) DEFAULT NULL,
  `F_b83aac23b9528732c23cc7352950e880` int(11) DEFAULT NULL,
  `F_cd00692c3bfe59267d5ecfac5310286c` int(11) DEFAULT NULL,
  `F_6faa8040da20ef399b63a72d0e4ab575` int(11) DEFAULT NULL,
  `F_fe73f687e5bc5280214e0486b273a5f9` int(11) DEFAULT NULL
1467
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1468
/*!40101 SET character_set_client = @saved_cs_client */;
1469 1470

LOCK TABLES `t1` WRITE;
1471
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
1472 1473
INSERT INTO `t1` (`F_c4ca4238a0b923820dcc509a6f75849b`, `F_c81e728d9d4c2f636f067f89cc14862c`, `F_eccbc87e4b5ce2fe28308fd9f2a7baf3`, `F_a87ff679a2f3e71d9181a67b7542122c`, `F_e4da3b7fbbce2345d7772b0674a318d5`, `F_1679091c5a880faf6fb5e6087eb1b2dc`, `F_8f14e45fceea167a5a36dedd4bea2543`, `F_c9f0f895fb98ab9159f51fd0297e236d`, `F_45c48cce2e2d7fbdea1afc51c7c6ad26`, `F_d3d9446802a44259755d38e6d163e820`, `F_6512bd43d9caa6e02c990b0a82652dca`, `F_c20ad4d76fe97759aa27a0c99bff6710`, `F_c51ce410c124a10e0db5e4b97fc2af39`, `F_aab3238922bcc25a6f606eb525ffdc56`, `F_9bf31c7ff062936a96d3c8bd1f8f2ff3`, `F_c74d97b01eae257e44aa9d5bade97baf`, `F_70efdf2ec9b086079795c442636b55fb`, `F_6f4922f45568161a8cdf4ad2299f6d23`, `F_1f0e3dad99908345f7439f8ffabdffc4`, `F_98f13708210194c475687be6106a3b84`, `F_3c59dc048e8850243be8079a5c74d079`, `F_b6d767d2f8ed5d21a44b0e5886680cb9`, `F_37693cfc748049e45d87b8c7d8b9aacd`, `F_1ff1de774005f8da13f42943881c655f`, `F_8e296a067a37563370ded05f5a3bf3ec`, `F_4e732ced3463d06de0ca9a15b6153677`, `F_02e74f10e0327ad868d138f2b4fdd6f0`, `F_33e75ff09dd601bbe69f351039152189`, `F_6ea9ab1baa0efb9e19094440c317e21b`, `F_34173cb38f07f89ddbebc2ac9128303f`, `F_c16a5320fa475530d9583c34fd356ef5`, `F_6364d3f0f495b6ab9dcf8d3b5c6e0b01`, `F_182be0c5cdcd5072bb1864cdee4d3d6e`, `F_e369853df766fa44e1ed0ff613f563bd`, `F_1c383cd30b7c298ab50293adfecb7b18`, `F_19ca14e7ea6328a42e0eb13d585e4c22`, `F_a5bfc9e07964f8dddeb95fc584cd965d`, `F_a5771bce93e200c36f7cd9dfd0e5deaa`, `F_d67d8ab4f4c10bf22aa353e27879133c`, `F_d645920e395fedad7bbbed0eca3fe2e0`, `F_3416a75f4cea9109507cacd8e2f2aefc`, `F_a1d0c6e83f027327d8461063f4ac58a6`, `F_17e62166fc8586dfa4d1bc0e1742c08b`, `F_f7177163c833dff4b38fc8d2872f1ec6`, `F_6c8349cc7260ae62e3b1396831a8398f`, `F_d9d4f495e875a2e075a1a4a6e1b9770f`, `F_67c6a1e7ce56d3d6fa748ab6d9af3fd7`, `F_642e92efb79421734881b53e1e1b18b6`, `F_f457c545a9ded88f18ecee47145a72c0`, `F_c0c7c76d30bd3dcaefc96f40275bdc0a`, `F_2838023a778dfaecdc212708f721b788`, `F_9a1158154dfa42caddbd0694a4e9bdc8`, `F_d82c8d1619ad8176d665453cfb2e55f0`, `F_a684eceee76fc522773286a895bc8436`, `F_b53b3a3d6ab90ce0268229151c9bde11`, `F_9f61408e3afb633e50cdf1b20de6f466`, `F_72b32a1f754ba1c09b3695e0cb6cde7f`, `F_66f041e16a60928b05a7e228a89c3799`, `F_093f65e080a295f8076b1c5722a46aa2`, `F_072b030ba126b2f4b2374f342be9ed44`, `F_7f39f8317fbdb1988ef4c628eba02591`, `F_44f683a84163b3523afe57c2e008bc8c`, `F_03afdbd66e7929b125f8597834fa83a4`, `F_ea5d2f1c4608232e07d3aa3d998e5135`, `F_fc490ca45c00b1249bbe3554a4fdf6fb`, `F_3295c76acbf4caaed33c36b1b5fc2cb1`, `F_735b90b4568125ed6c3f678819b6e058`, `F_a3f390d88e4c41f2747bfa2f1b5f87db`, `F_14bfa6bb14875e45bba028a21ed38046`, `F_7cbbc409ec990f19c78c75bd1e06f215`, `F_e2c420d928d4bf8ce0ff2ec19b371514`, `F_32bb90e8976aab5298d5da10fe66f21d`, `F_d2ddea18f00665ce8623e36bd4e3c7c5`, `F_ad61ab143223efbc24c7d2583be69251`, `F_d09bf41544a3365a46c9077ebb5e35c3`, `F_fbd7939d674997cdb4692d34de8633c4`, `F_28dd2c7955ce926456240b2ff0100bde`, `F_35f4a8d465e6e1edc05f3d8ab658c551`, `F_d1fe173d08e959397adf34b1d77e88d7`, `F_f033ab37c30201f73f142449d037028d`, `F_43ec517d68b6edd3015b3edc9a11367b`, `F_9778d5d219c5080b9a6a17bef029331c`, `F_fe9fc289c3ff0af142b6d3bead98a923`, `F_68d30a9594728bc39aa24be94b319d21`, `F_3ef815416f775098fe977004015c6193`, `F_93db85ed909c13838ff95ccfa94cebd9`, `F_c7e1249ffc03eb9ded908c236bd1996d`, `F_2a38a4a9316c49e5a833517c45d31070`, `F_7647966b7343c29048673252e490f736`, `F_8613985ec49eb8f757ae6439e879bb2a`, `F_54229abfcfa5649e7003b83dd4755294`, `F_92cc227532d17e56e07902b254dfad10`, `F_98dce83da57b0395e163467c9dae521b`, `F_f4b9ec30ad9f68f89b29639786cb62ef`, `F_812b4ba287f5ee0bc9d43bbf5bbe87fb`, `F_26657d5ff9020d2abefe558796b99584`, `F_e2ef524fbf3d9fe611d5a8e90fefdc9c`, `F_ed3d2c21991e3bef5e069713af9fa6ca`, `F_ac627ab1ccbdb62ec96e702f07f6425b`, `F_f899139df5e1059396431415e770c6dd`, `F_38b3eff8baf56627478ec76a704e9b52`, `F_ec8956637a99787bd197eacd77acce5e`, `F_6974ce5ac660610b44d9b9fed0ff9548`, `F_c9e1074f5b3f9fc8ea15d152add07294`, `F_65b9eea6e1cc6bb9f0cd2a47751a186f`, `F_f0935e4cd5920aa6c7c996a5ee53a70f`, `F_a97da629b098b75c294dffdc3e463904`, `F_a3c65c2974270fd093ee8a9bf8ae7d0b`, `F_2723d092b63885e0d7c260cc007e8b9d`, `F_5f93f983524def3dca464469d2cf9f3e`, `F_698d51a19d8a121ce581499d7b701668`, `F_7f6ffaa6bb0b408017b62254211691b5`, `F_73278a4a86960eeb576a8fd4c9ec6997`, `F_5fd0b37cd7dbbb00f97ba6ce92bf5add`, `F_2b44928ae11fb9384c4cf38708677c48`, `F_c45147dee729311ef5b5c3003946c48f`, `F_eb160de1de89d9058fcb0b968dbbbd68`, `F_5ef059938ba799aaa845e1c2e8a762bd`, `F_07e1cd7dca89a1678042477183b7ac3f`, `F_da4fb5c6e93e74d3df8527599fa62642`, `F_4c56ff4ce4aaf9573aa5dff913df997a`, `F_a0a080f42e6f13b3a2df133f073095dd`, `F_202cb962ac59075b964b07152d234b70`, `F_c8ffe9a587b126f152ed3d89a146b445`, `F_3def184ad8f4755ff269862ea77393dd`, `F_069059b7ef840f0c74a814ec9237b6ec`, `F_ec5decca5ed3d6b8079e2e7e7bacc9f2`, `F_76dc611d6ebaafc66cc0879c71b5db5c`, `F_d1f491a404d6854880943e5c3cd9ca25`, `F_9b8619251a19057cff70779273e95aa6`, `F_1afa34a7f984eeabdbb0a7d494132ee5`, `F_65ded5353c5ee48d0b7d48c591b8f430`, `F_9fc3d7152ba9336a670e36d0ed79bc43`, `F_02522a2b2726fb0a03bb19f2d8d9524d`, `F_7f1de29e6da19d22b51c68001e7e0e54`, `F_42a0e188f5033bc65bf8d78622277c4e`, `F_3988c7f88ebcb58c6ce932b957b6f332`, `F_013d407166ec4fa56eb1e1f8cbe183b9`, `F_e00da03b685a0dd18fb6a08af0923de0`, `F_1385974ed5904a438616ff7bdb3f7439`, `F_0f28b5d49b3020afeecd95b4009adf4c`, `F_a8baa56554f96369ab93e4f3bb068c22`, `F_903ce9225fca3e988c2af215d4e544d3`, `F_0a09c8844ba8f0936c20bd791130d6b6`, `F_2b24d495052a8ce66358eb576b8912c8`, `F_a5e00132373a7031000fd987a3c9f87b`, `F_8d5e957f297893487bd98fa830fa6413`, `F_47d1e990583c9c67424d369f3414728e`, `F_f2217062e9a397a1dca429e7d70bc6ca`, `F_7ef605fc8dba5425d6965fbd4c8fbe1f`, `F_a8f15eda80c50adb0e71943adc8015cf`, `F_37a749d808e46495a8da1e5352d03cae`, `F_b3e3e393c77e35a4a3f3cbd1e429b5dc`, `F_1d7f7abc18fcb43975065399b0d1e48e`, `F_2a79ea27c279e471f4d180b08d62b00a`, `F_1c9ac0159c94d8d0cbedc973445af2da`, `F_6c4b761a28b734fe93831e3fb400ce87`, `F_06409663226af2f3114485aa4e0a23b4`, `F_140f6969d5213fd0ece03148e62e461e`, `F_b73ce398c39f506af761d2277d853a92`, `F_bd4c9ab730f5513206b999ec0d90d1fb`, `F_82aa4b0af34c2313a562076992e50aa3`, `F_0777d5c17d4066b82ab86dff8a46af6f`, `F_fa7cdfad1a5aaf8370ebeda47a1ff1c3`, `F_9766527f2b5d3e95d4a733fcfb77bd7e`, `F_7e7757b1e12abcb736ab9a754ffb617a`, `F_5878a7ab84fb43402106c575658472fa`, `F_006f52e9102a8d3be2fe5614f42ba989`, `F_3636638817772e42b59d74cff571fbb3`, `F_149e9677a5989fd342ae44213df68868`, `F_a4a042cf4fd6bfb47701cbc8a1653ada`, `F_1ff8a7b5dc7a7d1f0ed65aaa29c04b1e`, `F_f7e6c85504ce6e82442c770f7c8606f0`, `F_bf8229696f7a3bb4700cfddef19fa23f`, `F_82161242827b703e6acf9c726942a1e4`, `F_38af86134b65d0f10fe33d30dd76442e`, `F_96da2f590cd7246bbde0051047b0d6f7`, `F_8f85517967795eeef66c225f7883bdcb`, `F_8f53295a73878494e9bc8dd6c3c7104f`, `F_045117b0e0a11a242b9765e79cbf113f`, `F_fc221309746013ac554571fbd180e1c8`, `F_4c5bde74a8f110656874902f07378009`, `F_cedebb6e872f539bef8c3f919874e9d7`, `F_6cdd60ea0045eb7a6ec44c54d29ed402`, `F_eecca5b6365d9607ee5a9d336962c534`, `F_9872ed9fc22fc182d371c3e9ed316094`, `F_31fefc0e570cb3860f2a6d4b38c6490d`, `F_9dcb88e0137649590b755372b040afad`, `F_a2557a7b2e94197ff767970b67041697`, `F_cfecdb276f634854f3ef915e2e980c31`, `F_0aa1883c6411f7873cb83dacb17b0afc`, `F_58a2fc6ed39fd083f55d4182bf88826d`, `F_bd686fd640be98efaae0091fa301e613`, `F_a597e50502f5ff68e3e25b9114205d4a`, `F_0336dcbab05b9d5ad24f4333c7658a0e`, `F_084b6fbb10729ed4da8c3d3f5a3ae7c9`, `F_85d8ce590ad8981ca2c8286f79f59954`, `F_0e65972dce68dad4d52d063967f0a705`, `F_84d9ee44e457ddef7f2c4f25dc8fa865`, `F_3644a684f98ea8fe223c713b77189a77`, `F_757b505cfd34c64c85ca5b5690ee5293`, `F_854d6fae5ee42911677c739ee1734486`, `F_e2c0be24560d78c5e599c2a9c9d0bbd2`, `F_274ad4786c3abca69fa097b85867d9a4`, `F_eae27d77ca20db309e056e3d2dcd7d69`, `F_7eabe3a1649ffa2b3ff8c02ebfd5659f`, `F_69adc1e107f7f7d035d7baf04342e1ca`, `F_091d584fced301b442654dd8c23b3fc9`, `F_b1d10e7bafa4421218a51b1e1f1b0ba2`, `F_6f3ef77ac0e3619e98159e9b6febf557`, `F_eb163727917cbba1eea208541a643e74`, `F_1534b76d325a8f591b52d302e7181331`, `F_979d472a84804b9f647bc185a877a8b5`, `F_ca46c1b9512a7a8315fa3c5a946e8265`, `F_3b8a614226a953a8cd9526fca6fe9ba5`, `F_45fbc6d3e05ebd93369ce542e8f2322d`, `F_63dc7ed1010d3c3b8269faf0ba7491d4`, `F_e96ed478dab8595a7dbda4cbcbee168f`, `F_c0e190d8267e36708f955d7ab048990d`, `F_ec8ce6abb3e952a85b8551ba726a1227`, `F_060ad92489947d410d897474079c1477`, `F_bcbe3365e6ac95ea2c0343a2395834dd`, `F_115f89503138416a242f40fb7d7f338e`, `F_13fe9d84310e77f13a6d184dbf1232f3`, `F_d1c38a09acc34845c6be3a127a5aacaf`, `F_9cfdf10e8fc047a44b08ed031e1f0ed1`, `F_705f2172834666788607efbfca35afb3`, `F_74db120f0a8e5646ef5a30154e9f6deb`, `F_57aeee35c98205091e18d1140e9f38cf`, `F_6da9003b743b65f4c0ccd295cc484e57`, `F_9b04d152845ec0a378394003c96da594`, `F_be83ab3ecd0db773eb2dc1b0a17836a1`, `F_e165421110ba03099a1c0393373c5b43`, `F_289dff07669d7a23de0ef88d2f7129e7`, `F_577ef1154f3240ad5b9b413aa7346a1e`, `F_01161aaa0b6d1345dd8fe4e481144d84`, `F_539fd53b59e3bb12d203f45a912eeaf2`, `F_ac1dd209cbcc5e5d1c6e28598e8cbbe8`, `F_555d6702c950ecb729a966504af0a635`, `F_335f5352088d7d9bf74191e006d8e24c`, `F_f340f1b1f65b6df5b5e3f94d95b11daf`, `F_e4a6222cdb5b34375400904f03d8e6a5`, `F_cb70ab375662576bd1ac5aaf16b3fca4`, `F_9188905e74c28e489b44e954ec0b9bca`, `F_0266e33d3f546cb5436a10798e657d97`, `F_38db3aed920cf82ab059bfccbd02be6a`, `F_3cec07e9ba5f5bb252d13f5f431e4bbb`, `F_621bf66ddb7c962aa0d22ac97d69b793`, `F_077e29b11be80ab57e1a2ecabb7da330`, `F_6c9882bbac1c7093bd25041881277658`, `F_19f3cd308f1455b3fa09a282e0d496f4`, `F_03c6b06952c750899bb03d998e631860`, `F_c24cd76e1ce41366a4bbe8a49b02a028`, `F_c52f1bd66cc19d05628bd8bf27af3ad6`, `F_fe131d7f5a6b38b23cc967316c13dae2`, `F_f718499c1c8cef6730f9fd03c8125cab`, `F_d96409bf894217686ba124d7356686c9`, `F_502e4a16930e414107ee22b6198c578f`, `F_cfa0860e83a4c3a763a7e62d825349f7`, `F_a4f23670e1833f3fdb077ca70bbd5d66`, `F_b1a59b315fc9a3002ce38bbe070ec3f5`, `F_36660e59856b4de58a219bcf4e27eba3`, `F_8c19f571e251e61cb8dd3612f26d5ecf`, `F_d6baf65e0b240ce177cf70da146c8dc8`, `F_e56954b4f6347e897f954495eab16a88`, `F_f7664060cc52bc6f3d620bcedc94a4b6`, `F_eda80a3d5b344bc40f3bc04f65b7a357`, `F_8f121ce07d74717e0b1f21d122e04521`, `F_06138bc5af6023646ede0e1f7c1eac75`, `F_39059724f73a9969845dfe4146c5660e`, `F_7f100b7b36092fb9b06dfb4fac360931`, `F_7a614fd06c325499f1680b9896beedeb`, `F_4734ba6f3de83d861c3176a6273cac6d`, `F_d947bf06a885db0d477d707121934ff8`, `F_63923f49e5241343aa7acb6a06a751e7`, `F_db8e1af0cb3aca1ae2d0018624204529`, `F_20f07591c6fcb220ffe637cda29bb3f6`, `F_07cdfd23373b17c6b337251c22b7ea57`, `F_d395771085aab05244a4fb8fd91bf4ee`, `F_92c8c96e4c37100777c7190b76d28233`, `F_e3796ae838835da0b6f6ea37bcf8bcb7`, `F_6a9aeddfc689c1d0e3b9ccc3ab651bc5`, `F_0f49c89d1e7298bb9930789c8ed59d48`, `F_46ba9f2a6976570b0353203ec4474217`, `F_0e01938fc48a2cfb5f2217fbfb00722d`, `F_16a5cdae362b8d27a1d8f8c7b78b4330`, `F_918317b57931b6b7a7d29490fe5ec9f9`, `F_48aedb8880cab8c45637abc7493ecddd`, `F_839ab46820b524afda05122893c2fe8e`, `F_f90f2aca5c640289d0a29417bcb63a37`, `F_9c838d2e45b2ad1094d42f4ef36764f6`, `F_1700002963a49da13542e0726b7bb758`, `F_53c3bce66e43be4f209556518c2fcb54`, `F_6883966fd8f918a4aa29be29d2c386fb`, `F_49182f81e6a13cf5eaa496d51fea6406`, `F_d296c101daa88a51f6ca8cfc1ac79b50`, `F_9fd81843ad7f202f26c1a174c7357585`, `F_26e359e83860db1d11b6acca57d8ea88`, `F_ef0d3930a7b6c95bd2b32ed45989c61f`, `F_94f6d7e04a4d452035300f18b984988c`, `F_34ed066df378efacc9b924ec161e7639`, `F_577bcc914f9e55d5e4e4f82f9f00e7d4`, `F_11b9842e0a271ff252c1903e7132cd68`, `F_37bc2f75bf1bcfe8450a1a41c200364c`, `F_496e05e1aea0a9c4655800e8a7b9ea28`, `F_b2eb7349035754953b57a32e2841bda5`, `F_8e98d81f8217304975ccb23337bb5761`, `F_a8c88a0055f636e4a163a5e3d16adab7`, `F_eddea82ad2755b24c4e168c5fc2ebd40`, `F_06eb61b839a0cefee4967c67ccb099dc`, `F_9dfcd5e558dfa04aaf37f137a1d9d3e5`, `F_950a4152c2b4aa3ad78bdd6b366cc179`, `F_158f3069a435b314a80bdcb024f8e422`, `F_758874998f5bd0c393da094e1967a72b`, `F_ad13a2a07ca4b7642959dc0c4c740ab6`, `F_3fe94a002317b5f9259f82690aeea4cd`, `F_5b8add2a5d98b1a652ea7fd72d942dac`, `F_432aca3a1e345e339f35a30c8f65edce`, `F_8d3bba7425e7c98c50f52ca1b52d3735`, `F_320722549d1751cf3f247855f937b982`, `F_caf1a3dfb505ffed0d024130f58c5cfa`, `F_5737c6ec2e0716f3d8a7a5c4e0de0d9a`, `F_bc6dc48b743dc5d013b1abaebd2faed2`, `F_f2fc990265c712c49d51a18a32b39f0c`, `F_89f0fd5c927d466d6ec9a21b9ac34ffa`, `F_a666587afda6e89aec274a3657558a27`, `F_b83aac23b9528732c23cc7352950e880`, `F_cd00692c3bfe59267d5ecfac5310286c`, `F_6faa8040da20ef399b63a72d0e4ab575`, `F_fe73f687e5bc5280214e0486b273a5f9`) VALUES (NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
1474
UNLOCK TABLES;
unknown's avatar
unknown committed
1475
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
1476 1477 1478 1479 1480 1481 1482 1483 1484 1485

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

drop table t1;
unknown's avatar
unknown committed
1486 1487 1488
#
# Test for --add-drop-database
#
unknown's avatar
unknown committed
1489 1490 1491 1492 1493 1494 1495
CREATE TABLE t1 (a int);
INSERT INTO t1 VALUES (1),(2),(3);

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
1496 1497
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

/*!40000 DROP DATABASE IF EXISTS `test`*/;

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `test`;
DROP TABLE IF EXISTS `t1`;
1509 1510
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
1511
CREATE TABLE `t1` (
1512
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
1513
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1514
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
1515 1516

LOCK TABLES `t1` WRITE;
1517
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
1518 1519
INSERT INTO `t1` VALUES (1),(2),(3);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
1520
UNLOCK TABLES;
unknown's avatar
unknown committed
1521
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
1522 1523 1524 1525 1526 1527 1528 1529 1530 1531

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

DROP TABLE t1;
unknown's avatar
unknown committed
1532
#
1533
# Bug#9558 mysqldump --no-data db t1 t2 format still dumps data
unknown's avatar
unknown committed
1534
#
unknown's avatar
unknown committed
1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545
CREATE DATABASE mysqldump_test_db;
USE mysqldump_test_db;
CREATE TABLE t1 ( a INT );
CREATE TABLE t2 ( a INT );
INSERT INTO t1 VALUES (1), (2);
INSERT INTO t2 VALUES (1), (2);

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
1546 1547
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
1548 1549 1550 1551 1552
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
1553 1554
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
1555
CREATE TABLE `t1` (
1556
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
1557
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1558
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
1559
DROP TABLE IF EXISTS `t2`;
1560 1561
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
1562
CREATE TABLE `t2` (
1563
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
1564
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1565
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
1566
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;


/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
1581 1582
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
1583 1584 1585 1586 1587
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
1588 1589
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
1590
CREATE TABLE `t1` (
1591
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
1592
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1593
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
1594
DROP TABLE IF EXISTS `t2`;
1595 1596
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
1597
CREATE TABLE `t2` (
1598
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
1599
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1600
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
1601
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
1602 1603 1604 1605 1606 1607 1608 1609 1610

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

1611
<?xml version="1.0"?>
unknown's avatar
unknown committed
1612
<mysqldump xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
1613 1614 1615 1616 1617 1618 1619 1620 1621 1622
<database name="mysqldump_test_db">
	<table_structure name="t1">
		<field Field="a" Type="int(11)" Null="YES" Key="" Extra="" />
	</table_structure>
	<table_structure name="t2">
		<field Field="a" Type="int(11)" Null="YES" Key="" Extra="" />
	</table_structure>
</database>
</mysqldump>
<?xml version="1.0"?>
unknown's avatar
unknown committed
1623
<mysqldump xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
1624 1625 1626 1627 1628 1629 1630 1631 1632
<database name="mysqldump_test_db">
	<table_structure name="t1">
		<field Field="a" Type="int(11)" Null="YES" Key="" Extra="" />
	</table_structure>
	<table_structure name="t2">
		<field Field="a" Type="int(11)" Null="YES" Key="" Extra="" />
	</table_structure>
</database>
</mysqldump>
unknown's avatar
unknown committed
1633 1634
DROP TABLE t1, t2;
DROP DATABASE mysqldump_test_db;
unknown's avatar
unknown committed
1635 1636 1637
#
#  Testing with tables and databases that don't exists
#  or contains illegal characters
1638
# (Bug#9358 mysqldump crashes if tablename starts with \)
unknown's avatar
unknown committed
1639
#
unknown's avatar
unknown committed
1640 1641 1642 1643 1644 1645 1646
create database mysqldump_test_db;
use mysqldump_test_db;
create table t1(a varchar(30) primary key, b int not null);
create table t2(a varchar(30) primary key, b int not null);
create table t3(a varchar(30) primary key, b int not null);
test_sequence
------ Testing with illegal table names ------
1647 1648 1649 1650 1651 1652 1653
mysqldump: Couldn't find table: "\d-2-1.sql"
mysqldump: Couldn't find table: "\t1"
mysqldump: Couldn't find table: "\t1"
mysqldump: Couldn't find table: "\\t1"
mysqldump: Couldn't find table: "t\1"
mysqldump: Couldn't find table: "t\1"
mysqldump: Couldn't find table: "t/1"
1654 1655 1656 1657 1658
mysqldump: Couldn't find table: "T_1"
mysqldump: Couldn't find table: "T%1"
mysqldump: Couldn't find table: "T'1"
mysqldump: Couldn't find table: "T_1"
mysqldump: Couldn't find table: "T_"
unknown's avatar
unknown committed
1659 1660
test_sequence
------ Testing with illegal database names ------
1661
mysqldump: Got error: 1049: Unknown database 'mysqldump_test_d' when selecting the database
1662
mysqldump: Got error: 1049: Unknown database 'mysqld\ump_test_db' when selecting the database
unknown's avatar
unknown committed
1663 1664
drop table t1, t2, t3;
drop database mysqldump_test_db;
1665
use test;
unknown's avatar
unknown committed
1666
#
1667
# Bug#9657 mysqldump xml ( -x ) does not format NULL fields correctly
unknown's avatar
unknown committed
1668
#
1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685
create table t1 (a int(10));
create table t2 (pk int primary key auto_increment,
a int(10), b varchar(30), c datetime, d blob, e text);
insert into t1 values (NULL), (10), (20);
insert into t2 (a, b) values (NULL, NULL),(10, NULL),(NULL, "twenty"),(30, "thirty");
<?xml version="1.0"?>
<mysqldump xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<database name="test">
	<table_data name="t1">
	<row>
		<field name="a" xsi:nil="true" />
	</row>
	<row>
		<field name="a">10</field>
	</row>
	<row>
		<field name="a">20</field>
1686
	</row>
1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724
	</table_data>
	<table_data name="t2">
	<row>
		<field name="pk">1</field>
		<field name="a" xsi:nil="true" />
		<field name="b" xsi:nil="true" />
		<field name="c" xsi:nil="true" />
		<field name="d" xsi:nil="true" />
		<field name="e" xsi:nil="true" />
	</row>
	<row>
		<field name="pk">2</field>
		<field name="a">10</field>
		<field name="b" xsi:nil="true" />
		<field name="c" xsi:nil="true" />
		<field name="d" xsi:nil="true" />
		<field name="e" xsi:nil="true" />
	</row>
	<row>
		<field name="pk">3</field>
		<field name="a" xsi:nil="true" />
		<field name="b">twenty</field>
		<field name="c" xsi:nil="true" />
		<field name="d" xsi:nil="true" />
		<field name="e" xsi:nil="true" />
	</row>
	<row>
		<field name="pk">4</field>
		<field name="a">30</field>
		<field name="b">thirty</field>
		<field name="c" xsi:nil="true" />
		<field name="d" xsi:nil="true" />
		<field name="e" xsi:nil="true" />
	</row>
	</table_data>
</database>
</mysqldump>
drop table t1, t2;
unknown's avatar
unknown committed
1725
#
1726
# Bug#12123 mysqldump --tab results in text file which can't be imported
unknown's avatar
unknown committed
1727
#
unknown's avatar
unknown committed
1728 1729 1730 1731
create table t1 (a text character set utf8, b text character set latin1);
insert t1 values (0x4F736E616272C3BC636B, 0x4BF66C6E);
select * from t1;
a	b
unknown's avatar
unknown committed
1732
Osnabrck	Kln
unknown's avatar
unknown committed
1733 1734 1735
test.t1: Records: 1  Deleted: 0  Skipped: 0  Warnings: 0
select * from t1;
a	b
unknown's avatar
unknown committed
1736
Osnabrck	Kln
1737
drop table t1;
unknown's avatar
unknown committed
1738
#
1739
# Bug#15328 Segmentation fault occured if my.cnf is invalid for escape sequence
unknown's avatar
unknown committed
1740
#
1741
--fields-optionally-enclosed-by="
unknown's avatar
unknown committed
1742
#
1743
# Bug#19025 mysqldump doesn't correctly dump "auto_increment = [int]"
unknown's avatar
unknown committed
1744
#
1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761
create table `t1` (
t1_name varchar(255) default null,
t1_id int(10) unsigned not null auto_increment,
key (t1_name),
primary key (t1_id)
) auto_increment = 1000 default charset=latin1;
insert into t1 (t1_name) values('bla');
insert into t1 (t1_name) values('bla');
insert into t1 (t1_name) values('bla');
select * from t1;
t1_name	t1_id
bla	1000
bla	1001
bla	1002
show create table `t1`;
Table	Create Table
t1	CREATE TABLE `t1` (
unknown's avatar
unknown committed
1762 1763 1764
  `t1_name` varchar(255) DEFAULT NULL,
  `t1_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  PRIMARY KEY (`t1_id`),
1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775
  KEY `t1_name` (`t1_name`)
) ENGINE=MyISAM AUTO_INCREMENT=1003 DEFAULT CHARSET=latin1
DROP TABLE `t1`;
select * from t1;
t1_name	t1_id
bla	1000
bla	1001
bla	1002
show create table `t1`;
Table	Create Table
t1	CREATE TABLE `t1` (
unknown's avatar
unknown committed
1776 1777 1778
  `t1_name` varchar(255) DEFAULT NULL,
  `t1_id` int(10) unsigned NOT NULL AUTO_INCREMENT,
  PRIMARY KEY (`t1_id`),
1779 1780 1781
  KEY `t1_name` (`t1_name`)
) ENGINE=MyISAM AUTO_INCREMENT=1003 DEFAULT CHARSET=latin1
drop table `t1`;
unknown's avatar
unknown committed
1782
#
1783
# Bug#18536 wrong table order
unknown's avatar
unknown committed
1784
#
1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799
create table t1(a int);
create table t2(a int);
create table t3(a int);

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t3`;
1800 1801
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
1802
CREATE TABLE `t3` (
1803
  `a` int(11) DEFAULT NULL
1804
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1805
/*!40101 SET character_set_client = @saved_cs_client */;
1806
DROP TABLE IF EXISTS `t1`;
1807 1808
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
1809
CREATE TABLE `t1` (
1810
  `a` int(11) DEFAULT NULL
1811
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1812
/*!40101 SET character_set_client = @saved_cs_client */;
1813
DROP TABLE IF EXISTS `t2`;
1814 1815
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
1816
CREATE TABLE `t2` (
1817
  `a` int(11) DEFAULT NULL
1818
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1819
/*!40101 SET character_set_client = @saved_cs_client */;
1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

drop table t1, t2, t3;
unknown's avatar
unknown committed
1831
#
1832
# Bug#21288 mysqldump segmentation fault when using --where
unknown's avatar
unknown committed
1833
#
1834 1835 1836
create table t1 (a int);
mysqldump: Couldn't execute 'SELECT /*!40001 SQL_NO_CACHE */ * FROM `t1` WHERE xx xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx': You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' at line 1 (1064)
mysqldump: Got error: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' at line 1 when retrieving data from server
1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
1849 1850
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
1851
CREATE TABLE `t1` (
1852
  `a` int(11) DEFAULT NULL
1853
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1854
/*!40101 SET character_set_client = @saved_cs_client */;
1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865

/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

1866
drop table t1;
1867
#
1868
# Bug#13926 --order-by-primary fails if PKEY contains quote character
1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884
#
DROP TABLE IF EXISTS `t1`;
CREATE TABLE `t1` (
`a b` INT,
`c"d` INT,
`e``f` INT,
PRIMARY KEY (`a b`, `c"d`, `e``f`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
insert into t1 values (0815, 4711, 2006);
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,ANSI' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS "t1";
1885 1886
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
1887 1888 1889 1890 1891 1892
CREATE TABLE "t1" (
  "a b" int(11) NOT NULL DEFAULT '0',
  "c""d" int(11) NOT NULL DEFAULT '0',
  "e`f" int(11) NOT NULL DEFAULT '0',
  PRIMARY KEY ("a b","c""d","e`f")
);
1893
/*!40101 SET character_set_client = @saved_cs_client */;
1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918

LOCK TABLES "t1" WRITE;
/*!40000 ALTER TABLE "t1" DISABLE KEYS */;
INSERT INTO "t1" VALUES (815,4711,2006);
/*!40000 ALTER TABLE "t1" ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;


/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
1919 1920
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
1921 1922 1923 1924 1925 1926
CREATE TABLE `t1` (
  `a b` int(11) NOT NULL DEFAULT '0',
  `c"d` int(11) NOT NULL DEFAULT '0',
  `e``f` int(11) NOT NULL DEFAULT '0',
  PRIMARY KEY (`a b`,`c"d`,`e``f`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1927
/*!40101 SET character_set_client = @saved_cs_client */;
1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944

LOCK TABLES `t1` WRITE;
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
INSERT INTO `t1` VALUES (815,4711,2006);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

DROP TABLE `t1`;
1945
End of 4.1 tests
unknown's avatar
unknown committed
1946
#
1947
# Bug#10213 mysqldump crashes when dumping VIEWs(on MacOS X)
unknown's avatar
unknown committed
1948
#
1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960
create database db1;
use db1;
CREATE TABLE t2 (
a varchar(30) default NULL,
KEY a (a(5))
);
INSERT INTO t2 VALUES ('alfred');
INSERT INTO t2 VALUES ('angie');
INSERT INTO t2 VALUES ('bingo');
INSERT INTO t2 VALUES ('waffle');
INSERT INTO t2 VALUES ('lemon');
create view v2 as select * from t2 where a like 'a%' with check option;
1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
1972
DROP TABLE IF EXISTS `t2`;
1973 1974
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
1975 1976 1977
CREATE TABLE `t2` (
  `a` varchar(30) DEFAULT NULL,
  KEY `a` (`a`(5))
1978
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
1979
/*!40101 SET character_set_client = @saved_cs_client */;
1980

1981 1982 1983 1984
LOCK TABLES `t2` WRITE;
/*!40000 ALTER TABLE `t2` DISABLE KEYS */;
INSERT INTO `t2` VALUES ('alfred'),('angie'),('bingo'),('waffle'),('lemon');
/*!40000 ALTER TABLE `t2` ENABLE KEYS */;
1985
UNLOCK TABLES;
1986 1987
DROP TABLE IF EXISTS `v2`;
/*!50001 DROP VIEW IF EXISTS `v2`*/;
1988 1989
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
1990 1991
/*!50001 CREATE TABLE `v2` (
  `a` varchar(30)
1992
) ENGINE=MyISAM */;
1993
SET character_set_client = @saved_cs_client;
1994
/*!50001 DROP TABLE IF EXISTS `v2`*/;
1995
/*!50001 DROP VIEW IF EXISTS `v2`*/;
unknown's avatar
unknown committed
1996 1997 1998 1999 2000 2001
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
2002 2003
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
2004
/*!50001 VIEW `v2` AS select `t2`.`a` AS `a` from `t2` where (`t2`.`a` like 'a%') */
2005
/*!50002 WITH CASCADED CHECK OPTION */;
unknown's avatar
unknown committed
2006 2007 2008
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
2009 2010 2011 2012 2013 2014 2015 2016 2017 2018
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

2019 2020 2021 2022
drop table t2;
drop view v2;
drop database db1;
use test;
unknown's avatar
unknown committed
2023
#
2024
# Bug#10713 mysqldump includes database in create view and referenced tables
unknown's avatar
unknown committed
2025
#
2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054
create database db2;
use db2;
create table t1 (a int);
create table t2 (a int, b varchar(10), primary key(a));
insert into t2 values (1, "on"), (2, "off"), (10, "pol"), (12, "meg");
insert into t1 values (289), (298), (234), (456), (789);
create view v1 as select * from t2;
create view v2 as select * from t1;
drop table t1, t2;
drop view v1, v2;
drop database db2;
use test;
create database db1;
use db1;
show tables;
Tables_in_db1
t1
t2
v1
v2
select * from t2 order by a;
a	b
1	on
2	off
10	pol
12	meg
drop table t1, t2;
drop database db1;
use test;
unknown's avatar
unknown committed
2055 2056 2057 2058 2059 2060 2061
create table t1(a int);
create view v1 as select * from t1;

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
2062 2063
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
2064 2065 2066 2067 2068
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
2069 2070
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
2071
CREATE TABLE `t1` (
2072
  `a` int(11) DEFAULT NULL
unknown's avatar
unknown committed
2073
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2074
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
2075 2076

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
2077
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
2078
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
2079
UNLOCK TABLES;
unknown's avatar
unknown committed
2080
DROP TABLE IF EXISTS `v1`;
unknown's avatar
unknown committed
2081
/*!50001 DROP VIEW IF EXISTS `v1`*/;
2082 2083
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
unknown's avatar
unknown committed
2084
/*!50001 CREATE TABLE `v1` (
2085
  `a` int(11)
2086
) ENGINE=MyISAM */;
2087
SET character_set_client = @saved_cs_client;
2088
/*!50001 DROP TABLE IF EXISTS `v1`*/;
unknown's avatar
unknown committed
2089
/*!50001 DROP VIEW IF EXISTS `v1`*/;
unknown's avatar
unknown committed
2090 2091 2092 2093 2094 2095
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
2096 2097 2098
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v1` AS select `t1`.`a` AS `a` from `t1` */;
unknown's avatar
unknown committed
2099 2100 2101
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
unknown's avatar
unknown committed
2102
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

drop view v1;
drop table t1;
unknown's avatar
unknown committed
2114
#
2115
# Bug#10213 mysqldump crashes when dumping VIEWs(on MacOS X)
unknown's avatar
unknown committed
2116
#
unknown's avatar
unknown committed
2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133
create database mysqldump_test_db;
use mysqldump_test_db;
CREATE TABLE t2 (
a varchar(30) default NULL,
KEY a (a(5))
);
INSERT INTO t2 VALUES ('alfred');
INSERT INTO t2 VALUES ('angie');
INSERT INTO t2 VALUES ('bingo');
INSERT INTO t2 VALUES ('waffle');
INSERT INTO t2 VALUES ('lemon');
create view v2 as select * from t2 where a like 'a%' with check option;

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
2134 2135
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
2136 2137 2138 2139 2140
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t2`;
2141 2142
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
2143
CREATE TABLE `t2` (
2144
  `a` varchar(30) DEFAULT NULL,
unknown's avatar
unknown committed
2145 2146
  KEY `a` (`a`(5))
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2147
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
2148 2149

LOCK TABLES `t2` WRITE;
unknown's avatar
unknown committed
2150
/*!40000 ALTER TABLE `t2` DISABLE KEYS */;
unknown's avatar
unknown committed
2151 2152
INSERT INTO `t2` VALUES ('alfred'),('angie'),('bingo'),('waffle'),('lemon');
/*!40000 ALTER TABLE `t2` ENABLE KEYS */;
unknown's avatar
unknown committed
2153
UNLOCK TABLES;
unknown's avatar
unknown committed
2154
DROP TABLE IF EXISTS `v2`;
unknown's avatar
unknown committed
2155
/*!50001 DROP VIEW IF EXISTS `v2`*/;
2156 2157
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
unknown's avatar
unknown committed
2158
/*!50001 CREATE TABLE `v2` (
2159
  `a` varchar(30)
2160
) ENGINE=MyISAM */;
2161
SET character_set_client = @saved_cs_client;
2162
/*!50001 DROP TABLE IF EXISTS `v2`*/;
unknown's avatar
unknown committed
2163
/*!50001 DROP VIEW IF EXISTS `v2`*/;
unknown's avatar
unknown committed
2164 2165 2166 2167 2168 2169
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
2170 2171
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
2172
/*!50001 VIEW `v2` AS select `t2`.`a` AS `a` from `t2` where (`t2`.`a` like 'a%') */
2173
/*!50002 WITH CASCADED CHECK OPTION */;
unknown's avatar
unknown committed
2174 2175 2176
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
unknown's avatar
unknown committed
2177
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

drop table t2;
drop view v2;
drop database mysqldump_test_db;
use test;
unknown's avatar
unknown committed
2191
#
2192
# Bug#9756 mysql client failing on dumps containing certain \ sequences
unknown's avatar
unknown committed
2193
#
unknown's avatar
unknown committed
2194 2195 2196 2197 2198 2199 2200
CREATE TABLE t1 (a char(10));
INSERT INTO t1 VALUES ('\'');

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
2201 2202
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
unknown's avatar
unknown committed
2203 2204 2205 2206 2207
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
2208 2209
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
2210
CREATE TABLE `t1` (
2211
  `a` char(10) DEFAULT NULL
unknown's avatar
unknown committed
2212
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2213
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
2214 2215

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
2216
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
2217 2218
INSERT INTO `t1` VALUES ('\'');
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
2219
UNLOCK TABLES;
unknown's avatar
unknown committed
2220
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
unknown's avatar
unknown committed
2221 2222 2223 2224 2225 2226 2227 2228 2229 2230

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

DROP TABLE t1;
unknown's avatar
unknown committed
2231
#
2232
# Bug#10927 mysqldump: Can't reload dump with view that consist of other view
unknown's avatar
unknown committed
2233
#
unknown's avatar
unknown committed
2234 2235 2236 2237 2238 2239 2240 2241
create table t1(a int, b int, c varchar(30));
insert into t1 values(1, 2, "one"), (2, 4, "two"), (3, 6, "three");
create view v3 as
select * from t1;
create  view v1 as
select * from v3 where b in (1, 2, 3, 4, 5, 6, 7);
create  view v2 as
select v3.a from v3, v1 where v1.a=v3.a and v3.b=3 limit 1;
2242 2243 2244 2245 2246

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
2247 2248
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
2249 2250 2251 2252 2253
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
2254 2255
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
2256
CREATE TABLE `t1` (
2257 2258 2259
  `a` int(11) DEFAULT NULL,
  `b` int(11) DEFAULT NULL,
  `c` varchar(30) DEFAULT NULL
2260
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2261
/*!40101 SET character_set_client = @saved_cs_client */;
2262 2263

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
2264
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
2265 2266
INSERT INTO `t1` VALUES (1,2,'one'),(2,4,'two'),(3,6,'three');
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
2267
UNLOCK TABLES;
2268 2269
DROP TABLE IF EXISTS `v1`;
/*!50001 DROP VIEW IF EXISTS `v1`*/;
2270 2271
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
2272
/*!50001 CREATE TABLE `v1` (
2273 2274 2275
  `a` int(11),
  `b` int(11),
  `c` varchar(30)
2276
) ENGINE=MyISAM */;
2277
SET character_set_client = @saved_cs_client;
2278 2279
DROP TABLE IF EXISTS `v2`;
/*!50001 DROP VIEW IF EXISTS `v2`*/;
2280 2281
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
2282
/*!50001 CREATE TABLE `v2` (
2283
  `a` int(11)
2284
) ENGINE=MyISAM */;
2285
SET character_set_client = @saved_cs_client;
2286 2287
DROP TABLE IF EXISTS `v3`;
/*!50001 DROP VIEW IF EXISTS `v3`*/;
2288 2289
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
2290
/*!50001 CREATE TABLE `v3` (
2291 2292 2293
  `a` int(11),
  `b` int(11),
  `c` varchar(30)
2294
) ENGINE=MyISAM */;
2295
SET character_set_client = @saved_cs_client;
2296
/*!50001 DROP TABLE IF EXISTS `v1`*/;
2297
/*!50001 DROP VIEW IF EXISTS `v1`*/;
unknown's avatar
unknown committed
2298 2299 2300 2301 2302 2303
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
2304 2305 2306
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v1` AS select `v3`.`a` AS `a`,`v3`.`b` AS `b`,`v3`.`c` AS `c` from `v3` where (`v3`.`b` in (1,2,3,4,5,6,7)) */;
unknown's avatar
unknown committed
2307 2308 2309
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
2310
/*!50001 DROP TABLE IF EXISTS `v2`*/;
2311
/*!50001 DROP VIEW IF EXISTS `v2`*/;
unknown's avatar
unknown committed
2312 2313 2314 2315 2316 2317
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
2318 2319 2320
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v2` AS select `v3`.`a` AS `a` from (`v3` join `v1`) where ((`v1`.`a` = `v3`.`a`) and (`v3`.`b` = 3)) limit 1 */;
unknown's avatar
unknown committed
2321 2322 2323
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
2324
/*!50001 DROP TABLE IF EXISTS `v3`*/;
2325
/*!50001 DROP VIEW IF EXISTS `v3`*/;
unknown's avatar
unknown committed
2326 2327 2328 2329 2330 2331
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
2332 2333 2334
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v3` AS select `t1`.`a` AS `a`,`t1`.`b` AS `b`,`t1`.`c` AS `c` from `t1` */;
unknown's avatar
unknown committed
2335 2336 2337
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
unknown's avatar
unknown committed
2338
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
2339 2340 2341 2342 2343 2344 2345 2346 2347

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

unknown's avatar
unknown committed
2348 2349
drop view v1, v2, v3;
drop table t1;
unknown's avatar
unknown committed
2350 2351 2352
#
# Test for dumping triggers
#
2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364
CREATE TABLE t1 (a int, b bigint default NULL);
CREATE TABLE t2 (a int);
create trigger trg1 before insert on t1 for each row
begin
if new.a > 10 then
set new.a := 10;
set new.a := 11;
end if;
end|
create trigger trg2 before update on t1 for each row begin
if old.a % 2 = 0 then set new.b := 12; end if;
end|
2365
set sql_mode="traditional"|
2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377
create trigger trg3 after update on t1 for each row
begin
if new.a = -1 then
set @fired:= "Yes";
end if;
end|
create trigger trg4 before insert on t2 for each row
begin
if new.a > 10 then
set @fired:= "No";
end if;
end|
2378
set sql_mode=default|
2379
show triggers like "t1";
unknown's avatar
unknown committed
2380
Trigger	Event	Table	Statement	Timing	Created	sql_mode	Definer	character_set_client	collation_connection	Database Collation
2381
trg1	INSERT	t1	begin
2382 2383 2384 2385
if new.a > 10 then
set new.a := 10;
set new.a := 11;
end if;
unknown's avatar
unknown committed
2386
end	BEFORE	0000-00-00 00:00:00		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
2387
trg2	UPDATE	t1	begin
2388
if old.a % 2 = 0 then set new.b := 12; end if;
unknown's avatar
unknown committed
2389
end	BEFORE	0000-00-00 00:00:00		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
2390
trg3	UPDATE	t1	begin
2391 2392 2393
if new.a = -1 then
set @fired:= "Yes";
end if;
unknown's avatar
unknown committed
2394
end	AFTER	0000-00-00 00:00:00	STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_AUTO_CREATE_USER	root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
2395 2396 2397 2398 2399 2400 2401
INSERT INTO t1 (a) VALUES (1),(2),(3),(22);
update t1 set a = 4 where a=3;

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
2402 2403
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
2404 2405 2406 2407 2408 2409 2410 2411 2412
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `test`;
DROP TABLE IF EXISTS `t1`;
2413 2414
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
2415
CREATE TABLE `t1` (
2416 2417
  `a` int(11) DEFAULT NULL,
  `b` bigint(20) DEFAULT NULL
2418
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2419
/*!40101 SET character_set_client = @saved_cs_client */;
2420

2421
LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
2422
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
2423 2424
INSERT INTO `t1` VALUES (1,NULL),(2,NULL),(4,NULL),(11,NULL);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
2425
UNLOCK TABLES;
unknown's avatar
unknown committed
2426 2427 2428 2429 2430 2431 2432 2433
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = '' */ ;
2434
DELIMITER ;;
unknown's avatar
unknown committed
2435 2436
/*!50003 CREATE*/ /*!50017 DEFINER=`root`@`localhost`*/ /*!50003 trigger trg1 before insert on t1 for each row
begin
2437 2438 2439 2440
if new.a > 10 then
set new.a := 10;
set new.a := 11;
end if;
2441
end */;;
unknown's avatar
unknown committed
2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456
DELIMITER ;
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = '' */ ;
DELIMITER ;;
/*!50003 CREATE*/ /*!50017 DEFINER=`root`@`localhost`*/ /*!50003 trigger trg2 before update on t1 for each row begin
2457
if old.a % 2 = 0 then set new.b := 12; end if;
2458
end */;;
unknown's avatar
unknown committed
2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474
DELIMITER ;
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = 'STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_AUTO_CREATE_USER' */ ;
DELIMITER ;;
/*!50003 CREATE*/ /*!50017 DEFINER=`root`@`localhost`*/ /*!50003 trigger trg3 after update on t1 for each row
begin
2475 2476 2477
if new.a = -1 then
set @fired:= "Yes";
end if;
2478 2479
end */;;
DELIMITER ;
unknown's avatar
unknown committed
2480 2481 2482 2483
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
2484
DROP TABLE IF EXISTS `t2`;
2485 2486
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
2487
CREATE TABLE `t2` (
2488
  `a` int(11) DEFAULT NULL
2489
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2490
/*!40101 SET character_set_client = @saved_cs_client */;
2491

2492
LOCK TABLES `t2` WRITE;
unknown's avatar
unknown committed
2493
/*!40000 ALTER TABLE `t2` DISABLE KEYS */;
2494
/*!40000 ALTER TABLE `t2` ENABLE KEYS */;
unknown's avatar
unknown committed
2495
UNLOCK TABLES;
unknown's avatar
unknown committed
2496 2497 2498 2499 2500 2501 2502 2503
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = 'STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_AUTO_CREATE_USER' */ ;
2504
DELIMITER ;;
unknown's avatar
unknown committed
2505 2506
/*!50003 CREATE*/ /*!50017 DEFINER=`root`@`localhost`*/ /*!50003 trigger trg4 before insert on t2 for each row
begin
2507 2508 2509
if new.a > 10 then
set @fired:= "No";
end if;
2510 2511
end */;;
DELIMITER ;
unknown's avatar
unknown committed
2512 2513 2514 2515
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
unknown's avatar
unknown committed
2516
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
2517

2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;


/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
2531 2532
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
2533 2534 2535 2536 2537 2538 2539 2540 2541
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `test`;
DROP TABLE IF EXISTS `t1`;
2542 2543
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
2544
CREATE TABLE `t1` (
2545 2546
  `a` int(11) DEFAULT NULL,
  `b` bigint(20) DEFAULT NULL
2547
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2548
/*!40101 SET character_set_client = @saved_cs_client */;
2549 2550

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
2551
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
2552 2553
INSERT INTO `t1` VALUES (1,NULL),(2,NULL),(4,NULL),(11,NULL);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
2554
UNLOCK TABLES;
2555
DROP TABLE IF EXISTS `t2`;
2556 2557
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
2558
CREATE TABLE `t2` (
2559
  `a` int(11) DEFAULT NULL
2560
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2561
/*!40101 SET character_set_client = @saved_cs_client */;
2562 2563

LOCK TABLES `t2` WRITE;
unknown's avatar
unknown committed
2564
/*!40000 ALTER TABLE `t2` DISABLE KEYS */;
2565
/*!40000 ALTER TABLE `t2` ENABLE KEYS */;
unknown's avatar
unknown committed
2566
UNLOCK TABLES;
unknown's avatar
unknown committed
2567
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

drop table t1;
show tables;
Tables_in_test
t1
t2
2582
show triggers;
unknown's avatar
unknown committed
2583
Trigger	Event	Table	Statement	Timing	Created	sql_mode	Definer	character_set_client	collation_connection	Database Collation
2584
trg1	INSERT	t1	begin
2585 2586 2587 2588
if new.a > 10 then
set new.a := 10;
set new.a := 11;
end if;
unknown's avatar
unknown committed
2589
end	BEFORE	#		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
2590
trg2	UPDATE	t1	begin
2591
if old.a % 2 = 0 then set new.b := 12; end if;
unknown's avatar
unknown committed
2592
end	BEFORE	#		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
2593
trg3	UPDATE	t1	begin
2594 2595 2596
if new.a = -1 then
set @fired:= "Yes";
end if;
unknown's avatar
unknown committed
2597
end	AFTER	#	STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_AUTO_CREATE_USER	root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
2598
trg4	INSERT	t2	begin
2599 2600 2601
if new.a > 10 then
set @fired:= "No";
end if;
unknown's avatar
unknown committed
2602
end	BEFORE	#	STRICT_TRANS_TABLES,STRICT_ALL_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,TRADITIONAL,NO_AUTO_CREATE_USER	root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
2603
DROP TABLE t1, t2;
unknown's avatar
unknown committed
2604
#
2605 2606 2607
# Bug#9136  my_print_defaults changed behaviour between 4.1.7 and 4.1.10a
# Bug#12917 The --defaults-extra-file option is ignored by the 5.0 client binaries
# (Problems with --defaults-extra-file option)
unknown's avatar
unknown committed
2608
#
2609 2610
--port=1234
--port=1234
unknown's avatar
unknown committed
2611
#
2612
# Test of fix to Bug#12597 mysqldump dumps triggers wrongly
unknown's avatar
unknown committed
2613
#
2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632
DROP TABLE IF EXISTS `test1`;
Warnings:
Note	1051	Unknown table 'test1'
CREATE TABLE `test1` (
`a1` int(11) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
DROP TABLE IF EXISTS `test2`;
Warnings:
Note	1051	Unknown table 'test2'
CREATE TABLE `test2` (
`a2` int(11) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
CREATE TRIGGER `testref` BEFORE INSERT ON `test1` FOR EACH ROW BEGIN
INSERT INTO test2 SET a2 = NEW.a1; END  //
INSERT INTO `test1` VALUES (1);
SELECT * FROM `test2`;
a2
1
SHOW TRIGGERS;
unknown's avatar
unknown committed
2633
Trigger	Event	Table	Statement	Timing	Created	sql_mode	Definer	character_set_client	collation_connection	Database Collation
2634
testref	INSERT	test1	BEGIN
unknown's avatar
unknown committed
2635
INSERT INTO test2 SET a2 = NEW.a1; END	BEFORE	NULL		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
2636 2637 2638 2639 2640 2641 2642 2643 2644
SELECT * FROM `test1`;
a1
1
SELECT * FROM `test2`;
a2
1
DROP TRIGGER testref;
DROP TABLE test1;
DROP TABLE test2;
unknown's avatar
unknown committed
2645
#
2646
# Bug#9056 mysqldump does not dump routines
unknown's avatar
unknown committed
2647
#
2648
DROP TABLE IF EXISTS t1;
2649
DROP FUNCTION IF EXISTS bug9056_func1;
2650 2651 2652
DROP FUNCTION IF EXISTS bug9056_func2;
DROP PROCEDURE IF EXISTS bug9056_proc1;
DROP PROCEDURE IF EXISTS bug9056_proc2;
2653
DROP PROCEDURE IF EXISTS `a'b`;
2654 2655 2656
CREATE TABLE t1 (id int);
INSERT INTO t1 VALUES(1), (2), (3), (4), (5);
CREATE FUNCTION `bug9056_func1`(a INT, b INT) RETURNS int(11) RETURN a+b //
2657 2658
CREATE PROCEDURE `bug9056_proc1`(IN a INT, IN b INT, OUT c INT)
BEGIN SELECT a+b INTO c; end  //
unknown's avatar
unknown committed
2659
create function bug9056_func2(f1 char binary) returns char
2660 2661 2662 2663
begin
set f1= concat( 'hello', f1 );
return f1;
end //
2664 2665 2666
CREATE PROCEDURE bug9056_proc2(OUT a INT)
BEGIN
select sum(id) from t1 into a;
2667
END //
2668 2669 2670
set sql_mode='ansi';
create procedure `a'b` () select 1;
set sql_mode='';
2671 2672 2673 2674 2675

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
unknown's avatar
unknown committed
2676 2677
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
2678 2679 2680 2681 2682 2683 2684 2685 2686
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `test`;
DROP TABLE IF EXISTS `t1`;
2687 2688
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
2689
CREATE TABLE `t1` (
2690
  `id` int(11) DEFAULT NULL
2691
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2692
/*!40101 SET character_set_client = @saved_cs_client */;
2693 2694

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
2695
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
2696 2697
INSERT INTO `t1` VALUES (1),(2),(3),(4),(5);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
2698
UNLOCK TABLES;
unknown's avatar
unknown committed
2699 2700 2701 2702 2703 2704 2705 2706 2707
/*!50003 DROP FUNCTION IF EXISTS `bug9056_func1` */;
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = '' */ ;
2708
DELIMITER ;;
2709
/*!50003 CREATE*/ /*!50020 DEFINER=`root`@`localhost`*/ /*!50003 FUNCTION `bug9056_func1`(a INT, b INT) RETURNS int(11)
2710
RETURN a+b */;;
unknown's avatar
unknown committed
2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725
DELIMITER ;
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
/*!50003 DROP FUNCTION IF EXISTS `bug9056_func2` */;
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = '' */ ;
DELIMITER ;;
2726
/*!50003 CREATE*/ /*!50020 DEFINER=`root`@`localhost`*/ /*!50003 FUNCTION `bug9056_func2`(f1 char binary) RETURNS char(1) CHARSET latin1
2727
begin
2728 2729
set f1= concat( 'hello', f1 );
return f1;
2730
end */;;
unknown's avatar
unknown committed
2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745
DELIMITER ;
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
/*!50003 DROP PROCEDURE IF EXISTS `a'b` */;
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = 'REAL_AS_FLOAT,PIPES_AS_CONCAT,ANSI_QUOTES,IGNORE_SPACE,ANSI' */ ;
DELIMITER ;;
2746
/*!50003 CREATE*/ /*!50020 DEFINER="root"@"localhost"*/ /*!50003 PROCEDURE "a'b"()
2747
select 1 */;;
unknown's avatar
unknown committed
2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762
DELIMITER ;
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
/*!50003 DROP PROCEDURE IF EXISTS `bug9056_proc1` */;
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = '' */ ;
DELIMITER ;;
2763
/*!50003 CREATE*/ /*!50020 DEFINER=`root`@`localhost`*/ /*!50003 PROCEDURE `bug9056_proc1`(IN a INT, IN b INT, OUT c INT)
2764
BEGIN SELECT a+b INTO c; end */;;
unknown's avatar
unknown committed
2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779
DELIMITER ;
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
/*!50003 DROP PROCEDURE IF EXISTS `bug9056_proc2` */;
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = '' */ ;
DELIMITER ;;
2780
/*!50003 CREATE*/ /*!50020 DEFINER=`root`@`localhost`*/ /*!50003 PROCEDURE `bug9056_proc2`(OUT a INT)
2781 2782
BEGIN
select sum(id) from t1 into a;
2783
END */;;
2784
DELIMITER ;
unknown's avatar
unknown committed
2785 2786 2787 2788
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
unknown's avatar
unknown committed
2789
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
2790 2791 2792 2793 2794 2795 2796 2797 2798

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

2799 2800 2801 2802
DROP FUNCTION bug9056_func1;
DROP FUNCTION bug9056_func2;
DROP PROCEDURE bug9056_proc1;
DROP PROCEDURE bug9056_proc2;
unknown's avatar
unknown committed
2803
DROP PROCEDURE `a'b`;
2804
drop table t1;
unknown's avatar
unknown committed
2805
#
2806
# Bug#13052 mysqldump timestamp reloads broken
unknown's avatar
unknown committed
2807
#
unknown's avatar
unknown committed
2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837
drop table if exists t1;
create table t1 (`d` timestamp, unique (`d`));
set time_zone='+00:00';
insert into t1 values ('2003-10-25 22:00:00'),('2003-10-25 23:00:00');
select * from t1;
d
2003-10-25 22:00:00
2003-10-25 23:00:00
set time_zone='Europe/Moscow';
select * from t1;
d
2003-10-26 02:00:00
2003-10-26 02:00:00
set global time_zone='Europe/Moscow';

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `test`;
DROP TABLE IF EXISTS `t1`;
2838 2839
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
2840
CREATE TABLE `t1` (
2841
  `d` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
unknown's avatar
unknown committed
2842 2843
  UNIQUE KEY `d` (`d`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2844
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
2845 2846

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
2847
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
2848 2849
INSERT INTO `t1` VALUES ('2003-10-25 22:00:00'),('2003-10-25 23:00:00');
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
2850
UNLOCK TABLES;
unknown's avatar
unknown committed
2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;


/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `test`;
DROP TABLE IF EXISTS `t1`;
2875 2876
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
2877
CREATE TABLE `t1` (
2878
  `d` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
unknown's avatar
unknown committed
2879 2880
  UNIQUE KEY `d` (`d`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
2881
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
2882 2883

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
2884
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
unknown's avatar
unknown committed
2885 2886
INSERT INTO `t1` VALUES ('2003-10-26 02:00:00'),('2003-10-26 02:00:00');
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
2887
UNLOCK TABLES;
unknown's avatar
unknown committed
2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

drop table t1;
set global time_zone=default;
set time_zone=default;
unknown's avatar
unknown committed
2900
#
2901
# Test of fix to Bug#13146 ansi quotes break loading of triggers
unknown's avatar
unknown committed
2902
#
unknown's avatar
unknown committed
2903
DROP TABLE IF EXISTS `t1 test`;
2904
DROP TABLE IF EXISTS `t2 test`;
unknown's avatar
unknown committed
2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927
CREATE TABLE `t1 test` (
`a1` int(11) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
CREATE TABLE `t2 test` (
`a2` int(11) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
CREATE TRIGGER `test trig` BEFORE INSERT ON `t1 test` FOR EACH ROW BEGIN
INSERT INTO `t2 test` SET a2 = NEW.a1; END  //
INSERT INTO `t1 test` VALUES (1);
INSERT INTO `t1 test` VALUES (2);
INSERT INTO `t1 test` VALUES (3);
SELECT * FROM `t2 test`;
a2
1
2
3
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,ANSI' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS "t1 test";
2928 2929
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
2930
CREATE TABLE "t1 test" (
2931
  "a1" int(11) DEFAULT NULL
unknown's avatar
unknown committed
2932
);
2933
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
2934 2935

LOCK TABLES "t1 test" WRITE;
unknown's avatar
unknown committed
2936
/*!40000 ALTER TABLE "t1 test" DISABLE KEYS */;
unknown's avatar
unknown committed
2937 2938
INSERT INTO "t1 test" VALUES (1),(2),(3);
/*!40000 ALTER TABLE "t1 test" ENABLE KEYS */;
unknown's avatar
unknown committed
2939
UNLOCK TABLES;
unknown's avatar
unknown committed
2940 2941 2942 2943 2944 2945 2946 2947
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = '' */ ;
unknown's avatar
unknown committed
2948
DELIMITER ;;
unknown's avatar
unknown committed
2949
/*!50003 CREATE*/ /*!50017 DEFINER=`root`@`localhost`*/ /*!50003 TRIGGER `test trig` BEFORE INSERT ON `t1 test` FOR EACH ROW BEGIN
unknown's avatar
unknown committed
2950 2951
INSERT INTO `t2 test` SET a2 = NEW.a1; END */;;
DELIMITER ;
unknown's avatar
unknown committed
2952 2953 2954 2955
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
unknown's avatar
unknown committed
2956
DROP TABLE IF EXISTS "t2 test";
2957 2958
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
2959
CREATE TABLE "t2 test" (
2960
  "a2" int(11) DEFAULT NULL
unknown's avatar
unknown committed
2961
);
2962
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
2963 2964

LOCK TABLES "t2 test" WRITE;
unknown's avatar
unknown committed
2965
/*!40000 ALTER TABLE "t2 test" DISABLE KEYS */;
unknown's avatar
unknown committed
2966 2967
INSERT INTO "t2 test" VALUES (1),(2),(3);
/*!40000 ALTER TABLE "t2 test" ENABLE KEYS */;
unknown's avatar
unknown committed
2968
UNLOCK TABLES;
unknown's avatar
unknown committed
2969 2970 2971 2972 2973 2974 2975 2976 2977 2978
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

DROP TRIGGER `test trig`;
DROP TABLE `t1 test`;
DROP TABLE `t2 test`;
unknown's avatar
unknown committed
2979
#
2980
# Bug#12838 mysqldump -x with views exits with error
unknown's avatar
unknown committed
2981
#
2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010
drop table if exists t1;
create table t1 (a int, b varchar(32), c varchar(32));
insert into t1 values (1, 'first value', 'xxxx');
insert into t1 values (2, 'second value', 'tttt');
insert into t1 values (3, 'third value', 'vvv vvv');
create view v1 as select * from t1;
create view v0 as select * from v1;
create view v2 as select * from v0;
select * from v2;
a	b	c
1	first value	xxxx
2	second value	tttt
3	third value	vvv vvv

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `test`;
DROP TABLE IF EXISTS `t1`;
3011 3012
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
3013
CREATE TABLE `t1` (
3014 3015 3016
  `a` int(11) DEFAULT NULL,
  `b` varchar(32) DEFAULT NULL,
  `c` varchar(32) DEFAULT NULL
3017
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
3018
/*!40101 SET character_set_client = @saved_cs_client */;
3019 3020

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
3021
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
3022 3023
INSERT INTO `t1` VALUES (1,'first value','xxxx'),(2,'second value','tttt'),(3,'third value','vvv vvv');
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
3024
UNLOCK TABLES;
3025 3026
DROP TABLE IF EXISTS `v0`;
/*!50001 DROP VIEW IF EXISTS `v0`*/;
3027 3028
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
3029 3030 3031 3032
/*!50001 CREATE TABLE `v0` (
  `a` int(11),
  `b` varchar(32),
  `c` varchar(32)
3033
) ENGINE=MyISAM */;
3034
SET character_set_client = @saved_cs_client;
3035 3036
DROP TABLE IF EXISTS `v1`;
/*!50001 DROP VIEW IF EXISTS `v1`*/;
3037 3038
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
3039 3040 3041 3042
/*!50001 CREATE TABLE `v1` (
  `a` int(11),
  `b` varchar(32),
  `c` varchar(32)
3043
) ENGINE=MyISAM */;
3044
SET character_set_client = @saved_cs_client;
3045 3046
DROP TABLE IF EXISTS `v2`;
/*!50001 DROP VIEW IF EXISTS `v2`*/;
3047 3048
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
3049 3050 3051 3052
/*!50001 CREATE TABLE `v2` (
  `a` int(11),
  `b` varchar(32),
  `c` varchar(32)
3053
) ENGINE=MyISAM */;
3054
SET character_set_client = @saved_cs_client;
3055 3056

USE `test`;
3057
/*!50001 DROP TABLE IF EXISTS `v0`*/;
3058
/*!50001 DROP VIEW IF EXISTS `v0`*/;
unknown's avatar
unknown committed
3059 3060 3061 3062 3063 3064
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
3065 3066 3067
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v0` AS select `v1`.`a` AS `a`,`v1`.`b` AS `b`,`v1`.`c` AS `c` from `v1` */;
unknown's avatar
unknown committed
3068 3069 3070
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
3071
/*!50001 DROP TABLE IF EXISTS `v1`*/;
3072
/*!50001 DROP VIEW IF EXISTS `v1`*/;
unknown's avatar
unknown committed
3073 3074 3075 3076 3077 3078
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
3079 3080 3081
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v1` AS select `t1`.`a` AS `a`,`t1`.`b` AS `b`,`t1`.`c` AS `c` from `t1` */;
unknown's avatar
unknown committed
3082 3083 3084
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
3085
/*!50001 DROP TABLE IF EXISTS `v2`*/;
3086
/*!50001 DROP VIEW IF EXISTS `v2`*/;
unknown's avatar
unknown committed
3087 3088 3089 3090 3091 3092
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
3093 3094 3095
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v2` AS select `v0`.`a` AS `a`,`v0`.`b` AS `b`,`v0`.`c` AS `c` from `v0` */;
unknown's avatar
unknown committed
3096 3097 3098
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

drop view v2;
drop view v0;
drop view v1;
drop table t1;
unknown's avatar
unknown committed
3113
#
3114
# Bug#14554 mysqldump does not separate words "ROW" and "BEGIN"
unknown's avatar
unknown committed
3115 3116
# for tables with trigger created in the IGNORE_SPACE sql mode.
#
3117 3118 3119 3120 3121 3122 3123 3124 3125
SET @old_sql_mode = @@SQL_MODE;
SET SQL_MODE = IGNORE_SPACE;
CREATE TABLE t1 (a INT);
CREATE TRIGGER tr1 BEFORE INSERT ON t1
FOR EACH ROW
BEGIN
SET new.a = 0;
END|
SET SQL_MODE = @old_sql_mode;
3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
3137 3138 3139 3140

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `test`;
3141
DROP TABLE IF EXISTS `t1`;
3142 3143
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
3144
CREATE TABLE `t1` (
3145
  `a` int(11) DEFAULT NULL
3146
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
3147
/*!40101 SET character_set_client = @saved_cs_client */;
3148 3149

LOCK TABLES `t1` WRITE;
3150
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
3151
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
3152
UNLOCK TABLES;
unknown's avatar
unknown committed
3153 3154 3155 3156 3157 3158 3159 3160
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = 'IGNORE_SPACE' */ ;
3161
DELIMITER ;;
unknown's avatar
unknown committed
3162 3163 3164
/*!50003 CREATE*/ /*!50017 DEFINER=`root`@`localhost`*/ /*!50003 TRIGGER tr1 BEFORE INSERT ON t1
FOR EACH ROW
BEGIN
3165 3166 3167
SET new.a = 0;
END */;;
DELIMITER ;
unknown's avatar
unknown committed
3168 3169 3170 3171
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
3172 3173 3174 3175 3176 3177 3178 3179 3180 3181
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

3182
DROP TRIGGER tr1;
3183
DROP TABLE t1;
unknown's avatar
unknown committed
3184
#
3185 3186
# Bug#13318 Bad result with empty field and --hex-blob
#
3187 3188
create table t1 (a binary(1), b blob);
insert into t1 values ('','');
3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
3201 3202
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
3203
CREATE TABLE `t1` (
3204 3205
  `a` binary(1) DEFAULT NULL,
  `b` blob
3206
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
3207
/*!40101 SET character_set_client = @saved_cs_client */;
3208 3209

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
3210
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
3211
INSERT INTO `t1` VALUES (0x00,'');
3212
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
3213
UNLOCK TABLES;
3214
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
3215

3216 3217 3218 3219 3220 3221 3222
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
3223

3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
3236 3237
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
3238 3239 3240 3241
CREATE TABLE `t1` (
  `a` binary(1) DEFAULT NULL,
  `b` blob
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
3242
/*!40101 SET character_set_client = @saved_cs_client */;
3243 3244 3245 3246 3247 3248

LOCK TABLES `t1` WRITE;
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
INSERT INTO `t1` VALUES (0x00,'');
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
UNLOCK TABLES;
3249 3250 3251 3252 3253 3254 3255 3256 3257 3258
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

3259
drop table t1;
unknown's avatar
unknown committed
3260
#
3261
# Bug#14871 Invalid view dump output
unknown's avatar
unknown committed
3262
#
3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288
create table t1 (a int);
insert into t1 values (289), (298), (234), (456), (789);
create definer = CURRENT_USER view v1 as select * from t1;
create SQL SECURITY INVOKER view v2 as select * from t1;
create view v3 as select * from t1 with local check option;
create algorithm=merge view v4 as select * from t1 with cascaded check option;
create algorithm =temptable view v5 as select * from t1;
drop table t1;
drop view v1, v2, v3, v4, v5;
show tables;
Tables_in_test
t1
v1
v2
v3
v4
v5
select * from v3 order by a;
a
234
289
298
456
789
drop table t1;
drop view v1, v2, v3, v4, v5;
unknown's avatar
unknown committed
3289
#
3290
# Bug#16878 dump of trigger
unknown's avatar
unknown committed
3291
#
unknown's avatar
unknown committed
3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304
create table t1 (a int, created datetime);
create table t2 (b int, created datetime);
create trigger tr1 before insert on t1 for each row set
new.created=now();
create trigger tr2 after insert on t1
for each row
begin
insert into t2 set b=new.a and created=new.created;
end|
drop trigger tr1;
drop trigger tr2;
drop table t1, t2;
show triggers;
unknown's avatar
unknown committed
3305
Trigger	Event	Table	Statement	Timing	Created	sql_mode	Definer	character_set_client	collation_connection	Database Collation
unknown's avatar
unknown committed
3306
tr1	INSERT	t1	set
unknown's avatar
unknown committed
3307
new.created=now()	BEFORE	#		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
unknown's avatar
unknown committed
3308 3309
tr2	INSERT	t1	begin
insert into t2 set b=new.a and created=new.created;
unknown's avatar
unknown committed
3310
end	AFTER	#		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
unknown's avatar
unknown committed
3311 3312 3313
drop trigger tr1;
drop trigger tr2;
drop table t1, t2;
unknown's avatar
unknown committed
3314 3315 3316
#
# Bug#18462 mysqldump does not dump view structures correctly
#
3317 3318 3319 3320 3321 3322
create table t (qty int, price int);
insert into t values(3, 50);
insert into t values(5, 51);
create view v1 as select qty, price, qty*price as value from t;
create view v2 as select qty from v1;
mysqldump {
3323
/*!50001 DROP TABLE IF EXISTS `v1`*/;
unknown's avatar
unknown committed
3324 3325 3326 3327 3328 3329
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
3330 3331 3332
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v1` AS select `t`.`qty` AS `qty`,`t`.`price` AS `price`,(`t`.`qty` * `t`.`price`) AS `value` from `t` */;
unknown's avatar
unknown committed
3333 3334 3335
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
3336 3337

} mysqldump {
3338
/*!50001 DROP TABLE IF EXISTS `v2`*/;
unknown's avatar
unknown committed
3339 3340 3341 3342 3343 3344
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
3345 3346 3347
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v2` AS select `v1`.`qty` AS `qty` from `v1` */;
unknown's avatar
unknown committed
3348 3349 3350
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
3351 3352 3353 3354 3355

} mysqldump
drop view v1;
drop view v2;
drop table t;
unknown's avatar
unknown committed
3356 3357
#
# Bug#14857 Reading dump files with single statement stored routines fails.
3358
# fixed by patch for Bug#16878
unknown's avatar
unknown committed
3359
#
3360 3361 3362 3363 3364
/*!50003 CREATE FUNCTION `f`() RETURNS bigint(20)
return 42 */|
/*!50003 CREATE PROCEDURE `p`()
select 42 */|
show create function f;
unknown's avatar
unknown committed
3365
Function	sql_mode	Create Function	character_set_client	collation_connection	Database Collation
3366
f		CREATE DEFINER=`root`@`localhost` FUNCTION `f`() RETURNS bigint(20)
unknown's avatar
unknown committed
3367
return 42	latin1	latin1_swedish_ci	latin1_swedish_ci
3368
show create procedure p;
unknown's avatar
unknown committed
3369
Procedure	sql_mode	Create Procedure	character_set_client	collation_connection	Database Collation
3370
p		CREATE DEFINER=`root`@`localhost` PROCEDURE `p`()
unknown's avatar
unknown committed
3371
select 42	latin1	latin1_swedish_ci	latin1_swedish_ci
3372 3373
drop function f;
drop procedure p;
unknown's avatar
unknown committed
3374
#
3375
# Bug#17371 Unable to dump a schema with invalid views
unknown's avatar
unknown committed
3376
#
3377 3378 3379 3380 3381 3382 3383 3384 3385
create table t1 ( id serial );
create view v1 as select * from t1;
drop table t1;
mysqldump {

-- failed on view `v1`: CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select `test`.`t1`.`id` AS `id` from `t1`

} mysqldump
drop view v1;
3386
# Bug#17201 Spurious 'DROP DATABASE' in output,
unknown's avatar
unknown committed
3387 3388
# also confusion between tables and views.
# Example code from Markus Popp
3389 3390
create database mysqldump_test_db;
use mysqldump_test_db;
3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408
create table t1 (id int);
create view v1 as select * from t1;
insert into t1 values (1232131);
insert into t1 values (4711);
insert into t1 values (3231);
insert into t1 values (0815);

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

3409
/*!40000 DROP DATABASE IF EXISTS `mysqldump_test_db`*/;
3410

3411
CREATE DATABASE /*!32312 IF NOT EXISTS*/ `mysqldump_test_db` /*!40100 DEFAULT CHARACTER SET latin1 */;
3412

3413
USE `mysqldump_test_db`;
3414
DROP TABLE IF EXISTS `t1`;
3415 3416
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
3417
CREATE TABLE `t1` (
3418
  `id` int(11) DEFAULT NULL
3419
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
3420
/*!40101 SET character_set_client = @saved_cs_client */;
3421 3422

LOCK TABLES `t1` WRITE;
unknown's avatar
unknown committed
3423
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
3424 3425
INSERT INTO `t1` VALUES (1232131),(4711),(3231),(815);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
unknown's avatar
unknown committed
3426
UNLOCK TABLES;
3427 3428
DROP TABLE IF EXISTS `v1`;
/*!50001 DROP VIEW IF EXISTS `v1`*/;
3429 3430
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
3431 3432
/*!50001 CREATE TABLE `v1` (
  `id` int(11)
3433
) ENGINE=MyISAM */;
3434
SET character_set_client = @saved_cs_client;
3435 3436

USE `mysqldump_test_db`;
3437
/*!50001 DROP TABLE IF EXISTS `v1`*/;
3438
/*!50001 DROP VIEW IF EXISTS `v1`*/;
unknown's avatar
unknown committed
3439 3440 3441 3442 3443 3444
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
3445 3446 3447
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v1` AS select `t1`.`id` AS `id` from `t1` */;
unknown's avatar
unknown committed
3448 3449 3450
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
3451 3452 3453 3454 3455 3456 3457 3458 3459 3460
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

unknown's avatar
unknown committed
3461
drop view v1;
3462 3463
drop table t1;
drop database mysqldump_test_db;
unknown's avatar
unknown committed
3464
#
3465
# Bug#21014 Segmentation fault of mysqldump on view
unknown's avatar
unknown committed
3466
#
3467 3468 3469 3470 3471 3472 3473 3474 3475 3476
create database mysqldump_tables;
use mysqldump_tables;
create table basetable ( id serial, tag varchar(64) );
create database mysqldump_views;
use mysqldump_views;
create view nasishnasifu as select mysqldump_tables.basetable.id from mysqldump_tables.basetable;

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `mysqldump_tables` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `mysqldump_tables`;
3477 3478
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
3479
CREATE TABLE `basetable` (
3480 3481
  `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
  `tag` varchar(64) DEFAULT NULL,
3482 3483
  UNIQUE KEY `id` (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
3484
/*!40101 SET character_set_client = @saved_cs_client */;
3485 3486 3487 3488

CREATE DATABASE /*!32312 IF NOT EXISTS*/ `mysqldump_views` /*!40100 DEFAULT CHARACTER SET latin1 */;

USE `mysqldump_views`;
3489 3490
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
3491 3492
/*!50001 CREATE TABLE `nasishnasifu` (
  `id` bigint(20) unsigned
3493
) ENGINE=MyISAM */;
3494
SET character_set_client = @saved_cs_client;
3495 3496 3497 3498

USE `mysqldump_tables`;

USE `mysqldump_views`;
3499
/*!50001 DROP TABLE IF EXISTS `nasishnasifu`*/;
unknown's avatar
unknown committed
3500 3501 3502 3503 3504 3505
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
3506 3507
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
3508
/*!50001 VIEW `nasishnasifu` AS select `mysqldump_tables`.`basetable`.`id` AS `id` from `mysqldump_tables`.`basetable` */;
unknown's avatar
unknown committed
3509 3510 3511
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
3512 3513 3514 3515
drop view nasishnasifu;
drop database mysqldump_views;
drop table mysqldump_tables.basetable;
drop database mysqldump_tables;
unknown's avatar
unknown committed
3516
#
3517
# Bug#20221 Dumping of multiple databases containing view(s) yields maleformed dumps
unknown's avatar
unknown committed
3518
#
3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549
create database mysqldump_dba;
use mysqldump_dba;
create table t1 (f1 int, f2 int);
insert into t1 values (1,1);
create view v1 as select f1, f2 from t1;
create database mysqldump_dbb;
use mysqldump_dbb;
create table t1 (f1 int, f2 int);
insert into t1 values (2,2);
create view v1 as select f1, f2 from t1;
drop view v1;
drop table t1;
drop database mysqldump_dbb;
use mysqldump_dba;
drop view v1;
drop table t1;
drop database mysqldump_dba;
select * from mysqldump_dba.v1;
f1	f2
1	1
select * from mysqldump_dbb.v1;
f1	f2
2	2
use mysqldump_dba;
drop view v1;
drop table t1;
drop database mysqldump_dba;
use mysqldump_dbb;
drop view v1;
drop table t1;
drop database mysqldump_dbb;
3550
use test;
unknown's avatar
unknown committed
3551 3552 3553
#
# Bug#21215 mysqldump creating incomplete backups without warning
#
unknown's avatar
unknown committed
3554
create user mysqltest_1@localhost;
3555
create table t1(a int, b varchar(34));
3556
reset master;
3557 3558
mysqldump: Couldn't execute 'FLUSH /*!40101 LOCAL */ TABLES': Access denied; you need the RELOAD privilege for this operation (1227)
mysqldump: Couldn't execute 'FLUSH /*!40101 LOCAL */ TABLES': Access denied; you need the RELOAD privilege for this operation (1227)
3559 3560 3561 3562 3563
grant RELOAD on *.* to mysqltest_1@localhost;
mysqldump: Couldn't execute 'SHOW MASTER STATUS': Access denied; you need the SUPER,REPLICATION CLIENT privilege for this operation (1227)
mysqldump: Couldn't execute 'SHOW MASTER STATUS': Access denied; you need the SUPER,REPLICATION CLIENT privilege for this operation (1227)
grant REPLICATION CLIENT on *.* to mysqltest_1@localhost;
drop table t1;
unknown's avatar
unknown committed
3564
drop user mysqltest_1@localhost;
unknown's avatar
unknown committed
3565
#
3566
# Bug#21424 mysqldump failing to export/import views
unknown's avatar
unknown committed
3567
#
3568 3569
create database mysqldump_myDB;
use mysqldump_myDB;
unknown's avatar
unknown committed
3570
create user myDB_User@localhost;
3571
grant create, create view, select, insert on mysqldump_myDB.* to myDB_User@localhost;
3572 3573 3574
create table t1 (c1 int);
insert into t1 values (3);
use mysqldump_myDB;
3575 3576
create table u1 (f1 int);
insert into u1 values (4);
3577 3578 3579 3580
create view v1 (c1) as select * from t1;
use mysqldump_myDB;
drop view v1;
drop table t1;
3581 3582
drop table u1;
revoke all privileges on mysqldump_myDB.* from myDB_User@localhost;
unknown's avatar
unknown committed
3583
drop user myDB_User@localhost;
3584 3585
drop database mysqldump_myDB;
flush privileges;
3586 3587
# Bug#21424 continues from here.
# Restore. Flush Privileges test ends.
unknown's avatar
unknown committed
3588
#
3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599
use mysqldump_myDB;
select * from mysqldump_myDB.v1;
c1
3
select * from mysqldump_myDB.u1;
f1
4
use mysqldump_myDB;
drop view v1;
drop table t1;
drop table u1;
3600
revoke all privileges on mysqldump_myDB.* from myDB_User@localhost;
unknown's avatar
unknown committed
3601
drop user myDB_User@localhost;
3602
drop database mysqldump_myDB;
3603
use test;
3604
#
3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637
# Bug #21527 mysqldump incorrectly tries to LOCK TABLES on the 
# information_schema database.
#
# Bug #33762: mysqldump can not dump INFORMATION_SCHEMA
#
DROP TABLE IF EXISTS `TABLES`;
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TEMPORARY TABLE `TABLES` (
  `TABLE_CATALOG` varchar(512) DEFAULT NULL,
  `TABLE_SCHEMA` varchar(64) NOT NULL DEFAULT '',
  `TABLE_NAME` varchar(64) NOT NULL DEFAULT '',
  `TABLE_TYPE` varchar(64) NOT NULL DEFAULT '',
  `ENGINE` varchar(64) DEFAULT NULL,
  `VERSION` bigint(21) unsigned DEFAULT NULL,
  `ROW_FORMAT` varchar(10) DEFAULT NULL,
  `TABLE_ROWS` bigint(21) unsigned DEFAULT NULL,
  `AVG_ROW_LENGTH` bigint(21) unsigned DEFAULT NULL,
  `DATA_LENGTH` bigint(21) unsigned DEFAULT NULL,
  `MAX_DATA_LENGTH` bigint(21) unsigned DEFAULT NULL,
  `INDEX_LENGTH` bigint(21) unsigned DEFAULT NULL,
  `DATA_FREE` bigint(21) unsigned DEFAULT NULL,
  `AUTO_INCREMENT` bigint(21) unsigned DEFAULT NULL,
  `CREATE_TIME` datetime DEFAULT NULL,
  `UPDATE_TIME` datetime DEFAULT NULL,
  `CHECK_TIME` datetime DEFAULT NULL,
  `TABLE_COLLATION` varchar(32) DEFAULT NULL,
  `CHECKSUM` bigint(21) unsigned DEFAULT NULL,
  `CREATE_OPTIONS` varchar(255) DEFAULT NULL,
  `TABLE_COMMENT` varchar(80) NOT NULL DEFAULT ''
) ENGINE=MEMORY DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
#
3638
# Bug#19745 mysqldump --xml produces invalid xml
unknown's avatar
unknown committed
3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659
#
DROP TABLE IF EXISTS t1;
CREATE TABLE t1 (f1 int(10), data MEDIUMBLOB);
INSERT INTO t1 VALUES(1,0xff00fef0);
<?xml version="1.0"?>
<mysqldump xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<database name="test">
	<table_structure name="t1">
		<field Field="f1" Type="int(10)" Null="YES" Key="" Extra="" />
		<field Field="data" Type="mediumblob" Null="YES" Key="" Extra="" />
	</table_structure>
	<table_data name="t1">
	<row>
		<field name="f1">1</field>
		<field name="data" xsi:type="xs:hexBinary">FF00FEF0</field>
	</row>
	</table_data>
</database>
</mysqldump>
DROP TABLE t1;
#
3660
# Bug#26346 stack + buffer overrun in mysqldump
3661 3662 3663
#
CREATE TABLE t1(a int);
INSERT INTO t1 VALUES (1), (2);
3664
mysqldump: Input filename too long: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
3665
DROP TABLE t1;
3666 3667 3668
CREATE TABLE t2 (a INT);
CREATE TABLE t3 (a INT);
CREATE TABLE t1 (a INT) ENGINE=merge UNION=(t2, t3);
unknown's avatar
unknown committed
3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
3681 3682
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
3683 3684 3685
CREATE TABLE `t1` (
  `a` int(11) DEFAULT NULL
) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t2`,`t3`);
3686
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
3687
DROP TABLE IF EXISTS `t2`;
3688 3689
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
3690 3691 3692
CREATE TABLE `t2` (
  `a` int(11) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
3693
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
3694 3695 3696 3697 3698 3699

LOCK TABLES `t2` WRITE;
/*!40000 ALTER TABLE `t2` DISABLE KEYS */;
/*!40000 ALTER TABLE `t2` ENABLE KEYS */;
UNLOCK TABLES;
DROP TABLE IF EXISTS `t3`;
3700 3701
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
3702 3703 3704
CREATE TABLE `t3` (
  `a` int(11) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
3705
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721

LOCK TABLES `t3` WRITE;
/*!40000 ALTER TABLE `t3` DISABLE KEYS */;
/*!40000 ALTER TABLE `t3` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

DROP TABLE t1, t2, t3;
3722
#
3723
# Bug#23491 MySQLDump prefix function call in a view by database name
unknown's avatar
unknown committed
3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736
#
create database bug23491_original;
create database bug23491_restore;
use bug23491_original;
create table t1 (c1 int);
create view v1 as select * from t1;
create procedure p1() select 1;
create function f1() returns int return 1;
create view v2 as select f1();
create function f2() returns int return f1();
create view v3 as select bug23491_original.f1();
use bug23491_restore;
show create view bug23491_restore.v2;
unknown's avatar
unknown committed
3737 3738
View	Create View	character_set_client	collation_connection
v2	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v2` AS select `f1`() AS `f1()`	latin1	latin1_swedish_ci
unknown's avatar
unknown committed
3739
show create view bug23491_restore.v3;
unknown's avatar
unknown committed
3740 3741
View	Create View	character_set_client	collation_connection
v3	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v3` AS select `bug23491_original`.`f1`() AS `bug23491_original.f1()`	latin1	latin1_swedish_ci
unknown's avatar
unknown committed
3742 3743 3744
drop database bug23491_original;
drop database bug23491_restore;
use test;
3745
#
3746 3747 3748 3749 3750
# Bug#27293 mysqldump crashes when dumping routines
#           defined by a different user
#
# Bug#22761 mysqldump reports no errors when using
#           --routines without mysql.proc privileges
3751 3752 3753 3754 3755
#
create database mysqldump_test_db;
grant all privileges on mysqldump_test_db.*  to user1;
grant all privileges on mysqldump_test_db.*  to user2;
create procedure mysqldump_test_db.sp1() select 'hello';
3756

3757 3758 3759
-- insufficient privileges to SHOW CREATE PROCEDURE `sp1`
-- does user2 have permissions on mysql.proc?

unknown's avatar
unknown committed
3760 3761 3762 3763 3764 3765 3766 3767
/*!50003 SET @saved_cs_client      = @@character_set_client */ ;
/*!50003 SET @saved_cs_results     = @@character_set_results */ ;
/*!50003 SET @saved_col_connection = @@collation_connection */ ;
/*!50003 SET character_set_client  = latin1 */ ;
/*!50003 SET character_set_results = latin1 */ ;
/*!50003 SET collation_connection  = latin1_swedish_ci */ ;
/*!50003 SET @saved_sql_mode       = @@sql_mode */ ;
/*!50003 SET sql_mode              = '' */ ;
3768 3769 3770 3771
DELIMITER ;;
/*!50003 CREATE*/ /*!50020 DEFINER=`user1`@`%`*/ /*!50003 PROCEDURE `sp1`()
select 'hello' */;;
DELIMITER ;
unknown's avatar
unknown committed
3772 3773 3774 3775
/*!50003 SET sql_mode              = @saved_sql_mode */ ;
/*!50003 SET character_set_client  = @saved_cs_client */ ;
/*!50003 SET character_set_results = @saved_cs_results */ ;
/*!50003 SET collation_connection  = @saved_col_connection */ ;
3776 3777 3778 3779
drop procedure sp1;
drop user user1;
drop user user2;
drop database mysqldump_test_db;
unknown's avatar
unknown committed
3780
#
3781
# Bug#28522 buffer overrun by '\0' byte using --hex-blob.
unknown's avatar
unknown committed
3782 3783 3784
#
CREATE TABLE t1 (c1 INT, c2 LONGBLOB);
INSERT INTO t1 SET c1=11, c2=REPEAT('q',509);
3785 3786
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
unknown's avatar
unknown committed
3787
CREATE TABLE `t1` (
unknown's avatar
unknown committed
3788
  `c1` int(11) DEFAULT NULL,
unknown's avatar
unknown committed
3789 3790
  `c2` longblob
);
3791
/*!40101 SET character_set_client = @saved_cs_client */;
unknown's avatar
unknown committed
3792 3793 3794
INSERT INTO `t1` VALUES (11,0x7171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171717171);
DROP TABLE t1;
#
3795 3796
# Bug#28524 mysqldump --skip-add-drop-table is not
#           compatible with views
unknown's avatar
unknown committed
3797 3798 3799 3800 3801 3802 3803 3804
#
CREATE VIEW v1 AS SELECT 1;
DROP VIEW v1;
SELECT * FROM v1;
1
1
DROP VIEW v1;
#
3805 3806
# Bug#29788 mysqldump discards the NO_AUTO_VALUE_ON_ZERO value of
#           the SQL_MODE variable after the dumping of triggers.
unknown's avatar
unknown committed
3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826
#
CREATE TABLE t1 (c1 INT);
CREATE TRIGGER t1bd BEFORE DELETE ON t1 FOR EACH ROW BEGIN END;
CREATE TABLE t2 (c1 INT NOT NULL AUTO_INCREMENT PRIMARY KEY);
SET @TMP_SQL_MODE = @@SQL_MODE;
SET SQL_MODE = 'NO_AUTO_VALUE_ON_ZERO';
INSERT INTO t2 VALUES (0), (1), (2);
SET SQL_MODE = @TMP_SQL_MODE;
SELECT * FROM t2;
c1
0
1
2
SELECT * FROM t2;
c1
0
1
2
DROP TABLE t1,t2;
#
3827 3828
# Bug#29815 new option for suppressing last line of mysqldump:
#           "Dump completed on"
unknown's avatar
unknown committed
3829 3830
#
# --skip-dump-date:
3831 3832 3833 3834
--



unknown's avatar
unknown committed
3835 3836
-- Dump completed
# --dump-date:
3837 3838 3839 3840
--



unknown's avatar
unknown committed
3841
-- Dump completed on DATE
unknown's avatar
unknown committed
3842
# --dump-date (default):
3843 3844 3845 3846
--



unknown's avatar
unknown committed
3847
-- Dump completed on DATE
unknown's avatar
unknown committed
3848
#
3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868
# Bug #42635: mysqldump includes views that were excluded using 
#   the --ignore-table option
#
create database db42635;
use db42635;
create table t1 (id int);
create view db42635.v1 (c) as select * from db42635.t1;
create view db42635.v2 (c) as select * from db42635.t1;

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
Chad MILLER's avatar
Chad MILLER committed
3869 3870
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
3871
CREATE TABLE `t1` (
3872
  `id` int(11) DEFAULT NULL
3873
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
Chad MILLER's avatar
Chad MILLER committed
3874
/*!40101 SET character_set_client = @saved_cs_client */;
3875 3876 3877 3878 3879 3880 3881

LOCK TABLES `t1` WRITE;
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
UNLOCK TABLES;
DROP TABLE IF EXISTS `v2`;
/*!50001 DROP VIEW IF EXISTS `v2`*/;
3882 3883
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
3884 3885 3886
/*!50001 CREATE TABLE `v2` (
  `c` int(11)
) ENGINE=MyISAM */;
3887
SET character_set_client = @saved_cs_client;
3888
/*!50001 DROP TABLE IF EXISTS `v2`*/;
3889
/*!50001 DROP VIEW IF EXISTS `v2`*/;
3890 3891 3892 3893 3894 3895
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
3896 3897 3898
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v2` AS select `t1`.`id` AS `c` from `t1` */;
3899 3900 3901
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

use test;
drop database db42635;
unknown's avatar
unknown committed
3914
#
3915 3916
# Bug#33550 mysqldump 4.0 compatibility broken
#
3917 3918 3919 3920 3921 3922 3923 3924 3925 3926
SET NAMES utf8;
CREATE TABLE `straße` ( f1 INT );
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,MYSQL323' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `straße`;
CREATE TABLE `straße` (
Tatiana A. Nurnberg's avatar
Tatiana A. Nurnberg committed
3927
  `f1` int(11) DEFAULT NULL
3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948
) TYPE=MyISAM;

LOCK TABLES `straße` WRITE;
/*!40000 ALTER TABLE `straße` DISABLE KEYS */;
/*!40000 ALTER TABLE `straße` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,MYSQL323' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `strae`;
CREATE TABLE `strae` (
Tatiana A. Nurnberg's avatar
Tatiana A. Nurnberg committed
3949
  `f1` int(11) DEFAULT NULL
3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972
) TYPE=MyISAM;

LOCK TABLES `strae` WRITE;
/*!40000 ALTER TABLE `strae` DISABLE KEYS */;
/*!40000 ALTER TABLE `strae` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

DROP TABLE `straße`;
CREATE TABLE `כדשגכחךלדגכחשךדגחכךלדגכ` ( f1 INT );
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,MYSQL323' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `כדשגכחךלדגכחשךדגחכךלדגכ`;
CREATE TABLE `כדשגכחךלדגכחשךדגחכךלדגכ` (
Tatiana A. Nurnberg's avatar
Tatiana A. Nurnberg committed
3973
  `f1` int(11) DEFAULT NULL
3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993
) TYPE=MyISAM;

LOCK TABLES `כדשגכחךלדגכחשךדגחכךלדגכ` WRITE;
/*!40000 ALTER TABLE `כדשגכחךלדגכחשךדגחכךלדגכ` DISABLE KEYS */;
/*!40000 ALTER TABLE `כדשגכחךלדגכחשךדגחכךלדגכ` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO,MYSQL323' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE `כדשגכחךלדגכחשךדגחכךלדגכ`;
3994
SET NAMES latin1;
unknown's avatar
unknown committed
3995
#
3996 3997
# End of 5.0 tests
#
3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014
drop table if exists t1;
CREATE TABLE t1(a int, b int);
INSERT INTO t1 VALUES (1,1);
INSERT INTO t1 VALUES (2,3);
INSERT INTO t1 VALUES (3,4), (4,5);

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
DROP TABLE IF EXISTS `t1`;
Tatiana A. Nurnberg's avatar
Tatiana A. Nurnberg committed
4015 4016
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
4017 4018 4019 4020
CREATE TABLE `t1` (
  `a` int(11) DEFAULT NULL,
  `b` int(11) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
Tatiana A. Nurnberg's avatar
Tatiana A. Nurnberg committed
4021
/*!40101 SET character_set_client = @saved_cs_client */;
4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038

LOCK TABLES `t1` WRITE;
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
REPLACE INTO `t1` VALUES (1,1),(2,3),(3,4),(4,5);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

DROP TABLE t1;
4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213
create table t1 (a text , b text);
create table t2 (a text , b text);
insert t1 values ("Duck, Duck", "goose");
insert t1 values ("Duck, Duck", "pidgeon");
insert t2 values ("We the people", "in order to perform");
insert t2 values ("a more perfect", "union");
select * from t1;
a	b
Duck, Duck	goose
Duck, Duck	pidgeon
select * from t2;
a	b
We the people	in order to perform
a more perfect	union
test.t1: Records: 2  Deleted: 0  Skipped: 0  Warnings: 0
test.t2: Records: 2  Deleted: 0  Skipped: 0  Warnings: 0
select * from t1;
a	b
Duck, Duck	goose
Duck, Duck	pidgeon
Duck, Duck	goose
Duck, Duck	pidgeon
select * from t2;
a	b
We the people	in order to perform
a more perfect	union
We the people	in order to perform
a more perfect	union
create table words(a varchar(255));
create table words2(b varchar(255));
select * from t1;
a	b
Duck, Duck	goose
Duck, Duck	pidgeon
Duck, Duck	goose
Duck, Duck	pidgeon
Duck, Duck	goose
Duck, Duck	pidgeon
select * from t2;
a	b
We the people	in order to perform
a more perfect	union
We the people	in order to perform
a more perfect	union
We the people	in order to perform
a more perfect	union
select * from words;
a
Aarhus
Aaron
Ababa
aback
abaft
abandon
abandoned
abandoning
abandonment
abandons
Aarhus
Aaron
Ababa
aback
abaft
abandon
abandoned
abandoning
abandonment
abandons
abase
abased
abasement
abasements
abases
abash
abashed
abashes
abashing
abasing
abate
abated
abatement
abatements
abater
abates
abating
Abba
abbe
abbey
abbeys
abbot
abbots
Abbott
abbreviate
abbreviated
abbreviates
abbreviating
abbreviation
abbreviations
Abby
abdomen
abdomens
abdominal
abduct
abducted
abduction
abductions
abductor
abductors
abducts
Abe
abed
Abel
Abelian
Abelson
Aberdeen
Abernathy
aberrant
aberration
select * from words2;
b
abase
abased
abasement
abasements
abases
abash
abashed
abashes
abashing
abasing
abate
abated
abatement
abatements
abater
abates
abating
Abba
abbe
abbey
abbeys
abbot
abbots
Abbott
abbreviate
abbreviated
abbreviates
abbreviating
abbreviation
abbreviations
Abby
abdomen
abdomens
abdominal
abduct
abducted
abduction
abductions
abductor
abductors
abducts
Abe
abed
Abel
Abelian
Abelson
Aberdeen
Abernathy
aberrant
aberration
drop table words;
mysql-import: Error: 1146, Table 'test.words' doesn't exist, when using table: words
drop table t1;
drop table t2;
drop table words2;
unknown's avatar
unknown committed
4214
#
Matthias Leich's avatar
Matthias Leich committed
4215
# Bug#16853 mysqldump doesn't show events
unknown's avatar
unknown committed
4216
#
4217 4218 4219 4220 4221
create database first;
use first;
set time_zone = 'UTC';
create event ee1 on schedule at '2035-12-31 20:01:23' do set @a=5;
show events;
unknown's avatar
unknown committed
4222 4223
Db	Name	Definer	Time zone	Type	Execute at	Interval value	Interval field	Starts	Ends	Status	Originator	character_set_client	collation_connection	Database Collation
first	ee1	root@localhost	UTC	ONE TIME	2035-12-31 20:01:23	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
4224
show create event ee1;
unknown's avatar
unknown committed
4225 4226
Event	sql_mode	time_zone	Create Event	character_set_client	collation_connection	Database Collation
ee1		UTC	CREATE EVENT `ee1` ON SCHEDULE AT '2035-12-31 20:01:23' ON COMPLETION NOT PRESERVE ENABLE DO set @a=5	latin1	latin1_swedish_ci	latin1_swedish_ci
4227 4228 4229 4230
drop database first;
create database second;
use second;
show events;
unknown's avatar
unknown committed
4231 4232
Db	Name	Definer	Time zone	Type	Execute at	Interval value	Interval field	Starts	Ends	Status	Originator	character_set_client	collation_connection	Database Collation
second	ee1	root@localhost	UTC	ONE TIME	2035-12-31 20:01:23	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
4233
show create event ee1;
unknown's avatar
unknown committed
4234 4235
Event	sql_mode	time_zone	Create Event	character_set_client	collation_connection	Database Collation
ee1		UTC	CREATE EVENT `ee1` ON SCHEDULE AT '2035-12-31 20:01:23' ON COMPLETION NOT PRESERVE ENABLE DO set @a=5	latin1	latin1_swedish_ci	latin1_swedish_ci
4236 4237 4238
create event ee2 on schedule at '2018-12-31 21:01:23' do set @a=5;
create event ee3 on schedule at '2030-12-31 22:01:23' do set @a=5;
show events;
unknown's avatar
unknown committed
4239 4240 4241 4242
Db	Name	Definer	Time zone	Type	Execute at	Interval value	Interval field	Starts	Ends	Status	Originator	character_set_client	collation_connection	Database Collation
second	ee1	root@localhost	UTC	ONE TIME	2035-12-31 20:01:23	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
second	ee2	root@localhost	UTC	ONE TIME	2018-12-31 21:01:23	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
second	ee3	root@localhost	UTC	ONE TIME	2030-12-31 22:01:23	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
4243 4244 4245 4246
drop database second;
create database third;
use third;
show events;
unknown's avatar
unknown committed
4247 4248 4249 4250
Db	Name	Definer	Time zone	Type	Execute at	Interval value	Interval field	Starts	Ends	Status	Originator	character_set_client	collation_connection	Database Collation
third	ee1	root@localhost	UTC	ONE TIME	2035-12-31 20:01:23	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
third	ee2	root@localhost	UTC	ONE TIME	2018-12-31 21:01:23	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
third	ee3	root@localhost	UTC	ONE TIME	2030-12-31 22:01:23	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
4251 4252 4253
drop database third;
set time_zone = 'SYSTEM';
use test;
unknown's avatar
unknown committed
4254
#
Matthias Leich's avatar
Matthias Leich committed
4255
# Bug#17201 Spurious 'DROP DATABASE' in output,
unknown's avatar
unknown committed
4256 4257 4258
# also confusion between tables and views.
# Example code from Markus Popp
#
4259 4260
create database mysqldump_test_db;
use mysqldump_test_db;
4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278
create table t1 (id int);
create view v1 as select * from t1;
insert into t1 values (1232131);
insert into t1 values (4711);
insert into t1 values (3231);
insert into t1 values (0815);

/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;

4279
/*!40000 DROP DATABASE IF EXISTS `mysqldump_test_db`*/;
4280

4281
CREATE DATABASE /*!32312 IF NOT EXISTS*/ `mysqldump_test_db` /*!40100 DEFAULT CHARACTER SET latin1 */;
4282

4283
USE `mysqldump_test_db`;
4284
DROP TABLE IF EXISTS `t1`;
Tatiana A. Nurnberg's avatar
Tatiana A. Nurnberg committed
4285 4286
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
4287
CREATE TABLE `t1` (
unknown's avatar
unknown committed
4288
  `id` int(11) DEFAULT NULL
4289
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
Tatiana A. Nurnberg's avatar
Tatiana A. Nurnberg committed
4290
/*!40101 SET character_set_client = @saved_cs_client */;
4291 4292

LOCK TABLES `t1` WRITE;
4293
/*!40000 ALTER TABLE `t1` DISABLE KEYS */;
4294 4295
INSERT INTO `t1` VALUES (1232131),(4711),(3231),(815);
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
4296
UNLOCK TABLES;
4297 4298
DROP TABLE IF EXISTS `v1`;
/*!50001 DROP VIEW IF EXISTS `v1`*/;
4299 4300
SET @saved_cs_client     = @@character_set_client;
SET character_set_client = utf8;
4301 4302
/*!50001 CREATE TABLE `v1` (
  `id` int(11)
4303
) ENGINE=MyISAM */;
4304
SET character_set_client = @saved_cs_client;
4305 4306

USE `mysqldump_test_db`;
4307
/*!50001 DROP TABLE IF EXISTS `v1`*/;
4308
/*!50001 DROP VIEW IF EXISTS `v1`*/;
unknown's avatar
unknown committed
4309 4310 4311 4312 4313 4314
/*!50001 SET @saved_cs_client          = @@character_set_client */;
/*!50001 SET @saved_cs_results         = @@character_set_results */;
/*!50001 SET @saved_col_connection     = @@collation_connection */;
/*!50001 SET character_set_client      = latin1 */;
/*!50001 SET character_set_results     = latin1 */;
/*!50001 SET collation_connection      = latin1_swedish_ci */;
4315 4316 4317
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`localhost` SQL SECURITY DEFINER */
/*!50001 VIEW `v1` AS select `t1`.`id` AS `id` from `t1` */;
unknown's avatar
unknown committed
4318 4319 4320
/*!50001 SET character_set_client      = @saved_cs_client */;
/*!50001 SET character_set_results     = @saved_cs_results */;
/*!50001 SET collation_connection      = @saved_col_connection */;
4321 4322 4323 4324 4325 4326 4327 4328 4329 4330
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

unknown's avatar
unknown committed
4331
drop view v1;
4332 4333
drop table t1;
drop database mysqldump_test_db;
unknown's avatar
unknown committed
4334
#
Matthias Leich's avatar
Matthias Leich committed
4335 4336
# Bug#30027 mysqldump does not dump views properly.
#
4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347

# Cleanup.
DROP DATABASE IF EXISTS mysqldump_test_db;

# Create objects.
CREATE DATABASE mysqldump_test_db;
set names koi8r;
CREATE VIEW mysqldump_test_db.v2 AS SELECT 1 AS 1;
CREATE VIEW mysqldump_test_db.v1 AS SELECT 1 FROM mysqldump_test_db.v2;
set names latin1;

4348
# Dump mysqldump_test_db to bug30027.sql.
4349 4350 4351 4352

# Drop mysqldump_test_db.
DROP DATABASE mysqldump_test_db;

4353
# Restore mysqldump_test_db from bug30027.sql.
4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367

# Check the view.
set names utf8;
SHOW CREATE VIEW mysqldump_test_db.v1;
View	Create View	character_set_client	collation_connection
v1	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `mysqldump_test_db`.`v1` AS select `v2`.`колонка1` AS `колонка1` from `mysqldump_test_db`.`v2`	koi8r	koi8r_general_ci
SHOW CREATE VIEW mysqldump_test_db.v2;
View	Create View	character_set_client	collation_connection
v2	CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `mysqldump_test_db`.`v2` AS select 1 AS `колонка1`	koi8r	koi8r_general_ci
set names latin1;

# Cleanup.
DROP DATABASE mysqldump_test_db;
#
Matthias Leich's avatar
Matthias Leich committed
4368 4369
# Bug#29938 wrong behavior of mysqldump --skip-events
#           with --all-databases
unknown's avatar
unknown committed
4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380
#
TRUNCATE mysql.event;
USE test;
CREATE event e29938 ON SCHEDULE AT '2035-12-31 20:01:23' DO SET @bug29938=29938;
SHOW EVENTS;
Db	Name	Definer	Time zone	Type	Execute at	Interval value	Interval field	Starts	Ends	Status	Originator	character_set_client	collation_connection	Database Collation
test	e29938	root@localhost	SYSTEM	ONE TIME	2035-12-31 20:01:23	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
TRUNCATE mysql.event;
SHOW EVENTS;
Db	Name	Definer	Time zone	Type	Execute at	Interval value	Interval field	Starts	Ends	Status	Originator	character_set_client	collation_connection	Database Collation
#
4381 4382 4383 4384 4385 4386
# Bug#31113 mysqldump 5.1 can't handle a dash ("-") in database names
#
create database `test-database`;
use `test-database`;
create table test (a int);
DROP TABLE IF EXISTS `test`;
Tatiana A. Nurnberg's avatar
Tatiana A. Nurnberg committed
4387 4388
/*!40101 SET @saved_cs_client     = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
4389 4390 4391
CREATE TABLE `test` (
  `a` int(11) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
Tatiana A. Nurnberg's avatar
Tatiana A. Nurnberg committed
4392
/*!40101 SET character_set_client = @saved_cs_client */;
4393 4394 4395 4396 4397 4398
LOCK TABLES `test` WRITE;
/*!40000 ALTER TABLE `test` DISABLE KEYS */;
/*!40000 ALTER TABLE `test` ENABLE KEYS */;
UNLOCK TABLES;
drop database `test-database`;
use test;
4399 4400

# -----------------------------------------------------------------
Matthias Leich's avatar
Matthias Leich committed
4401
# -- Bug#30217 Views: changes in metadata behaviour between 5.0 and 5.1.
4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432
# -----------------------------------------------------------------

DROP DATABASE IF EXISTS mysqldump_test_db;
CREATE DATABASE mysqldump_test_db;
use mysqldump_test_db;

CREATE VIEW v1(x, y) AS SELECT 'a', 'a';

SELECT view_definition
FROM INFORMATION_SCHEMA.VIEWS
WHERE table_schema = 'mysqldump_test_db' AND table_name = 'v1';
view_definition
select 'a' AS `x`,'a' AS `y`

---> Dumping mysqldump_test_db to bug30217.sql

DROP DATABASE mysqldump_test_db;
use test;

---> Restoring mysqldump_test_db...

SELECT view_definition
FROM INFORMATION_SCHEMA.VIEWS
WHERE table_schema = 'mysqldump_test_db' AND table_name = 'v1';
view_definition
select 'a' AS `x`,'a' AS `y`

DROP DATABASE mysqldump_test_db;

# -- End of test case for Bug#32538.

4433 4434 4435 4436 4437 4438 4439 4440 4441
#
# Bug#37377 Incorrect DROP TABLE statement in dump of a VIEW using --tab
#
create table t1 (a int);
create view v1 as select a from t1;
drop view v1;
drop table t1;
drop view v1;
drop table t1;
4442 4443 4444 4445 4446 4447 4448 4449 4450 4451
#
# Bug#28071 mysqlimport does not quote or escape table name
#
drop table if exists `load`;
create table `load` (a varchar(255));
test.load: Records: 70  Deleted: 0  Skipped: 0  Warnings: 0
select count(*) from `load`;
count(*)
70
drop table `load`;
4452
SET @@GLOBAL.CONCURRENT_INSERT = @OLD_CONCURRENT_INSERT;
4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503

Bug #34861 - mysqldump with --tab gives weird output for triggers.

CREATE TABLE t1 (f1 INT);
CREATE TRIGGER tr1 BEFORE UPDATE ON t1 FOR EACH ROW SET @f1 = 1;
CREATE PROCEDURE pr1 () SELECT "Meow";
CREATE EVENT ev1 ON SCHEDULE AT '2030-01-01 00:00:00' DO SELECT "Meow";

SHOW TRIGGERS;
Trigger	Event	Table	Statement	Timing	Created	sql_mode	Definer	character_set_client	collation_connection	Database Collation
tr1	UPDATE	t1	SET @f1 = 1	BEFORE	NULL		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
SHOW EVENTS;
Db	Name	Definer	Time zone	Type	Execute at	Interval value	Interval field	Starts	Ends	Status	Originator	character_set_client	collation_connection	Database Collation
test	ev1	root@localhost	SYSTEM	ONE TIME	2030-01-01 00:00:00	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
SELECT name,body FROM mysql.proc WHERE NAME = 'pr1';
name	body
pr1	SELECT "Meow"

dump table; if anything goes to stdout, it ends up here: ---------------

drop everything
DROP EVENT ev1;
DROP TRIGGER tr1;
DROP TABLE t1;
DROP PROCEDURE pr1;

reload table; this should restore table and trigger
SHOW TRIGGERS;
Trigger	Event	Table	Statement	Timing	Created	sql_mode	Definer	character_set_client	collation_connection	Database Collation
tr1	UPDATE	t1	SET @f1 = 1	BEFORE	NULL		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
SHOW EVENTS;
Db	Name	Definer	Time zone	Type	Execute at	Interval value	Interval field	Starts	Ends	Status	Originator	character_set_client	collation_connection	Database Collation
SELECT name,body FROM mysql.proc WHERE NAME = 'pr1';
name	body

reload db; this should restore routines and events
SHOW TRIGGERS;
Trigger	Event	Table	Statement	Timing	Created	sql_mode	Definer	character_set_client	collation_connection	Database Collation
tr1	UPDATE	t1	SET @f1 = 1	BEFORE	NULL		root@localhost	latin1	latin1_swedish_ci	latin1_swedish_ci
SHOW EVENTS;
Db	Name	Definer	Time zone	Type	Execute at	Interval value	Interval field	Starts	Ends	Status	Originator	character_set_client	collation_connection	Database Collation
test	ev1	root@localhost	SYSTEM	ONE TIME	2030-01-01 00:00:00	NULL	NULL	NULL	NULL	ENABLED	1	latin1	latin1_swedish_ci	latin1_swedish_ci
SELECT name,body FROM mysql.proc WHERE NAME = 'pr1';
name	body
pr1	SELECT "Meow"

cleanup
DROP EVENT IF EXISTS ev1;
DROP PROCEDURE IF EXISTS pr1;
DROP TRIGGER IF EXISTS tr1;
DROP TABLE IF EXISTS t1;
4504
#
4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563
# Bug #30946: mysqldump silently ignores --default-character-set
#             when used with --tab
#
# Also see outfile_loaddata.test
#
SET NAMES utf8;
CREATE TABLE t1 (a INT, b CHAR(10) CHARSET koi8r, c CHAR(10) CHARSET latin1);
CREATE TABLE t2 LIKE t1;
INSERT INTO t1 VALUES (1, 'ABC-АБВ', 'DEF-ÂÃÄ'), (2, NULL, NULL);
# error on multi-character ENCLOSED/ESCAPED BY
# default '--default-charset' (binary):
##################################################
1	ABC-	DEF-
2	\N	\N
##################################################
TRUNCATE t2;
LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/t1.txt' INTO TABLE t2 CHARACTER SET binary;
SELECT * FROM t1 UNION SELECT * FROM t2 ORDER BY a, b, c;
a	b	c
1	ABC-АБВ	DEF-ÂÃÄ
2	NULL	NULL
# utf8:
##################################################
1	ABC-АБВ	DEF-ÂÃÄ
2	\N	\N
##################################################
TRUNCATE t2;
LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/t1.txt' INTO TABLE t2 CHARACTER SET utf8;
SELECT * FROM t1 UNION SELECT * FROM t2 ORDER BY a, b, c;
a	b	c
1	ABC-АБВ	DEF-ÂÃÄ
2	NULL	NULL
# latin1 (data corruption is expected):
##################################################
1	ABC-???	DEF-
2	\N	\N
##################################################
TRUNCATE t2;
LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/t1.txt' INTO TABLE t2 CHARACTER SET latin1 ;
SELECT * FROM t1 UNION SELECT * FROM t2 ORDER BY a, b, c;
a	b	c
1	ABC-???	DEF-ÂÃÄ
1	ABC-АБВ	DEF-ÂÃÄ
2	NULL	NULL
# koi8r (data corruption is expected):
##################################################
1	ABC-	DEF-???
2	\N	\N
##################################################
TRUNCATE t2;
LOAD DATA INFILE 'MYSQLTEST_VARDIR/tmp/t1.txt' INTO TABLE t2 CHARACTER SET koi8r;
SELECT * FROM t1 UNION SELECT * FROM t2 ORDER BY a, b, c;
a	b	c
1	ABC-АБВ	DEF-???
1	ABC-АБВ	DEF-ÂÃÄ
2	NULL	NULL
SET NAMES default;
DROP TABLE t1, t2;
#
unknown's avatar
unknown committed
4564 4565
# End of 5.1 tests
#