mysqltest.result 19.4 KB
Newer Older
holyfoot@deer.(none)'s avatar
holyfoot@deer.(none) committed
1
select 0 as "before_use_test" ;
2
before_use_test
holyfoot@deer.(none)'s avatar
holyfoot@deer.(none) committed
3
0
4 5 6 7 8 9
select otto from (select 1 as otto) as t1;
otto
1
select otto from (select 1 as otto) as t1;
otto
1
10
mysqltest: At line 1: query 'select friedrich from (select 1 as otto) as t1' failed: 1054: Unknown column 'friedrich' in 'field list'
11 12 13 14 15
select friedrich from (select 1 as otto) as t1;
ERROR 42S22: Unknown column 'friedrich' in 'field list'
select otto from (select 1 as otto) as t1;
otto
1
16
mysqltest: At line 1: query 'select otto from (select 1 as otto) as t1' succeeded - should have failed with sqlstate 42S22...
17 18
select friedrich from (select 1 as otto) as t1;
ERROR 42S22: Unknown column 'friedrich' in 'field list'
19
mysqltest: At line 1: query 'select friedrich from (select 1 as otto) as t1' failed with wrong sqlstate 42S22: 'Unknown column 'friedrich' in 'field list'', instead of 00000...
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135
select otto from (select 1 as otto) as t1;
otto
1
select 0 as "after_successful_stmt_errno" ;
after_successful_stmt_errno
0
garbage ;
ERROR 42000: 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 'garbage' at line 1
select 1064 as "after_wrong_syntax_errno" ;
after_wrong_syntax_errno
1064
garbage ;
ERROR 42000: 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 'garbage' at line 1
select 1064 as "after_let_var_equal_value" ;
after_let_var_equal_value
1064
garbage ;
ERROR 42000: 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 'garbage' at line 1
set @my_var= 'abc' ;
select 0 as "after_set_var_equal_value" ;
after_set_var_equal_value
0
garbage ;
ERROR 42000: 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 'garbage' at line 1
select 1064 as "after_disable_warnings_command" ;
after_disable_warnings_command
1064
drop table if exists t1 ;
garbage ;
ERROR 42000: 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 'garbage' at line 1
drop table if exists t1 ;
select 0 as "after_disable_warnings" ;
after_disable_warnings
0
garbage ;
ERROR 42000: 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 'garbage' at line 1
select 3 from t1 ;
ERROR 42S02: Table 'test.t1' doesn't exist
select 1146 as "after_minus_masked" ;
after_minus_masked
1146
garbage ;
ERROR 42000: 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 'garbage' at line 1
select 3 from t1 ;
ERROR 42S02: Table 'test.t1' doesn't exist
select 1146 as "after_!_masked" ;
after_!_masked
1146
garbage ;
ERROR 42000: 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 'garbage' at line 1
select -1 as "after_let_errno_equal_value" ;
after_let_errno_equal_value
-1
garbage ;
ERROR 42000: 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 'garbage' at line 1
prepare stmt from "select 3 from t1" ;
ERROR 42S02: Table 'test.t1' doesn't exist
select 1146 as "after_failing_prepare" ;
after_failing_prepare
1146
create table t1 ( f1 char(10));
garbage ;
ERROR 42000: 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 'garbage' at line 1
prepare stmt from "select 3 from t1" ;
select 0 as "after_successful_prepare" ;
after_successful_prepare
0
garbage ;
ERROR 42000: 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 'garbage' at line 1
execute stmt;
3
select 0 as "after_successful_execute" ;
after_successful_execute
0
drop table t1;
garbage ;
ERROR 42000: 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 'garbage' at line 1
execute stmt;
ERROR 42S02: Table 'test.t1' doesn't exist
select 1146 as "after_failing_execute" ;
after_failing_execute
1146
garbage ;
ERROR 42000: 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 'garbage' at line 1
execute __stmt_;
ERROR HY000: Unknown prepared statement handler (__stmt_) given to EXECUTE
select 1243 as "after_failing_execute" ;
after_failing_execute
1243
garbage ;
ERROR 42000: 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 'garbage' at line 1
deallocate prepare stmt;
select 0 as "after_successful_deallocate" ;
after_successful_deallocate
0
garbage ;
ERROR 42000: 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 'garbage' at line 1
deallocate prepare __stmt_;
ERROR HY000: Unknown prepared statement handler (__stmt_) given to DEALLOCATE PREPARE
select 1243 as "after_failing_deallocate" ;
after_failing_deallocate
1243
garbage ;
ERROR 42000: 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 'garbage' at line 1
select 1064 as "after_--disable_abort_on_error" ;
after_--disable_abort_on_error
1064
select 3 from t1 ;
ERROR 42S02: Table 'test.t1' doesn't exist
select 3 from t1 ;
ERROR 42S02: Table 'test.t1' doesn't exist
select 3 from t1 ;
ERROR 42S02: Table 'test.t1' doesn't exist
select 1146 as "after_!errno_masked_error" ;
after_!errno_masked_error
1146
136
mysqltest: At line 1: query 'select 3 from t1' failed with wrong errno 1146: 'Table 'test.t1' doesn't exist', instead of 1000...
137 138 139 140 141 142 143
garbage ;
ERROR 42000: 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 'garbage' at line 1
select 1064 as "after_--enable_abort_on_error" ;
after_--enable_abort_on_error
1064
select 3 from t1 ;
ERROR 42S02: Table 'test.t1' doesn't exist
144
mysqltest: At line 1: query 'select 3 from t1' failed with wrong errno 1146: 'Table 'test.t1' doesn't exist', instead of 1064...
145 146 147 148 149 150 151
hello
hello
;;;;;;;;
# MySQL: -- The
mysqltest: At line 1: End of line junk detected: "6"
mysqltest: At line 1: End of line junk detected: "6"
mysqltest: At line 1: Missing delimiter
152 153 154
mysqltest: At line 1: End of line junk detected: "sleep 7
# Another comment
"
155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171
mysqltest: At line 1: Missing delimiter
mysqltest: At line 1: Missing delimiter
mysqltest: At line 1: End of line junk detected: "disconnect default

#
# comment
# comment2

# comment 3
--disable_query_log
"
mysqltest: At line 1: End of line junk detected: "disconnect default # comment
# comment part2

# comment 3
--disable_query_log
"
172
mysqltest: At line 1: Extra delimiter ";" found
173 174 175 176 177 178 179 180 181 182
mysqltest: At line 1: Extra delimiter ";" found
mysqltest: At line 1: Missing argument(s) to 'error'
mysqltest: At line 1: Missing argument(s) to 'error'
mysqltest: At line 1: The sqlstate definition must start with an uppercase S
mysqltest: At line 1: The error name definition must start with an uppercase E
mysqltest: At line 1: Invalid argument to error: '9eeeee' - the errno may only consist of digits[0-9]
mysqltest: At line 1: Invalid argument to error: '1sssss' - the errno may only consist of digits[0-9]
mysqltest: At line 1: The sqlstate must be exactly 5 chars long
mysqltest: At line 1: The sqlstate may only consist of digits[0-9] and _uppercase_ letters
mysqltest: At line 1: The sqlstate must be exactly 5 chars long
183
mysqltest: At line 1: Unknown SQL error name 'E9999'
184 185 186
mysqltest: At line 1: Invalid argument to error: '999e9' - the errno may only consist of digits[0-9]
mysqltest: At line 1: Invalid argument to error: '9b' - the errno may only consist of digits[0-9]
mysqltest: At line 1: Too many errorcodes specified
187 188 189 190 191 192 193 194 195 196 197 198 199 200
MySQL
"MySQL"
MySQL: The world''s most popular open source database
"MySQL: The world's most popular open source database"
MySQL: The world''s
most popular open
source database
# MySQL: The world''s
# most popular open
# source database
- MySQL: The world''s
- most popular open
- source database
- MySQL: The world''s
201 202
-- most popular
-- open source database
203 204 205 206 207 208 209 210 211 212 213
# MySQL: The
--world''s
# most popular
-- open
- source database
"MySQL: The world's most popular; open source database"
"MySQL: The world's most popular ; open source database"
"MySQL: The world's most popular ;open source database"
echo message echo message

mysqltest: At line 1: Empty variable
214
mysqltest: At line 1: command "false" failed
215 216 217 218 219 220 221 222 223 224 225 226 227
mysqltest: At line 1: Missing argument in exec
MySQL
"MySQL"
MySQL: The
world''s most
popular open
source database
# MySQL: The
# world''s most
# popular open
# source database
-- MySQL: The
-- world''s most
228 229
-- popular
-- open source database
230 231 232 233
# MySQL: The
- world''s most
-- popular open
# source database
234 235 236 237 238 239 240 241
'# MySQL: The
- world''s most
-- popular open
# source database'
"# MySQL: The
- world''s most
-- popular open
# source database"
242 243 244
hej
hej 
hej
245 246 247 248 249
1


a long variable content
a long variable content
250 251
a long a long variable content variable content
a long \$where variable content
252

253 254
banana = banana
Not a banana: ba\$cat\$cat
255 256 257 258
mysqltest: At line 1: Missing arguments to let
mysqltest: At line 1: Missing variable name in let
mysqltest: At line 1: Missing assignment operator in let
mysqltest: At line 1: Missing assignment operator in let
259 260
mysqltest: At line 1: Missing assignment operator in let
mysqltest: At line 1: Missing variable name in let
261 262
mysqltest: At line 1: Missing variable name in let
mysqltest: At line 1: Missing assignment operator in let
263 264 265 266 267 268 269 270 271 272
# Execute: --echo # <whatever> success: $success
# <whatever> success: 1
# Execute: echo # <whatever> success: $success ;
# <whatever> success: 1 
# The next two variants work fine and expand the content of $success
# Execute: --echo $success
1
# Execute: echo $success ;
1 
mysqltest: At line 1: Missing required argument 'filename' to command 'source'
273
mysqltest: At line 1: Could not open file ./non_existingFile
274 275
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/recursive.sql": At line 1: Source directives are nesting too deep
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/error.sql": At line 1: query 'garbage ' failed: 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 'garbage' at line 1
276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330

2 = outer loop variable after while
here is the sourced script

2 = outer loop variable before dec

1 = outer loop variable after dec

1 = outer loop variable after while
here is the sourced script

1 = outer loop variable before dec

0 = outer loop variable after dec

2 = outer loop variable after while
here is the sourced script

2 = outer loop variable before dec

1 = outer loop variable after dec

1 = outer loop variable after while
here is the sourced script

1 = outer loop variable before dec

0 = outer loop variable after dec

In loop
here is the sourced script

In loop
here is the sourced script

In loop
here is the sourced script

In loop
here is the sourced script

In loop
here is the sourced script

In loop
here is the sourced script

In loop
here is the sourced script

In loop
here is the sourced script

In loop
here is the sourced script
331
mysqltest: At line 1: Missing argument to sleep
332
mysqltest: At line 1: Missing argument to real_sleep
333
mysqltest: At line 1: Invalid argument to sleep "abc"
334
mysqltest: At line 1: Invalid argument to real_sleep "abc"
335 336 337 338 339
1
2
101
hej
1
340 341
mysqltest: At line 1: Missing argument to inc
mysqltest: At line 1: The argument to inc must be a variable (start with $)
342 343 344 345 346 347 348 349
mysqltest: At line 1: End of line junk detected: "1000"
4
4
-1
-2
99
hej
-1
350 351
mysqltest: At line 1: Missing argument to dec
mysqltest: At line 1: The argument to dec must be a variable (start with $)
352 353 354
mysqltest: At line 1: End of line junk detected: "1000"
mysqltest: At line 1: Missing arguments to system, nothing to do!
mysqltest: At line 1: Missing arguments to system, nothing to do!
355
mysqltest: At line 1: system command 'false' failed
356
system command 'NonExistsinfComamdn 2> /dev/null' failed
357 358 359 360
test
test2
test3
test4
361 362
Counter is greater than 0, (counter=10)
Counter is not 0, (counter=0)
363
1
364 365
Testing while with not
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/mysqltest_while.inc": At line 64: Nesting too deeply
366 367 368 369
mysqltest: At line 1: missing '(' in while
mysqltest: At line 1: missing ')' in while
mysqltest: At line 1: Missing '{' after while. Found "dec $i"
mysqltest: At line 1: Stray '}' - end of block before beginning
370
mysqltest: At line 1: Stray 'end' command - end of block before beginning
371
mysqltest: At line 1: query '{' failed: 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 '{' at line 1
372 373
mysqltest: At line 1: Missing '{' after while. Found "echo hej"
mysqltest: At line 3: Missing end of block
374
mysqltest: At line 3: Missing end of block
375 376 377 378 379 380 381 382 383 384 385 386
mysqltest: At line 1: missing '(' in if
mysqltest: At line 1: Stray 'end' command - end of block before beginning
select "b" bs col1, "c" bs col2;
col1	col2
b	c
seledt "b" bs dol1, "d" bs dol2;
dol1	dol2
b	d
mysqltest: At line 1: Wrong number of arguments to replace_result in 'replace_result a'
mysqltest: At line 1: Wrong number of arguments to replace_result in 'replace_result a;'
mysqltest: At line 1: Wrong number of arguments to replace_result in 'replace_result a'
mysqltest: At line 1: Wrong number of arguments to replace_result in 'replace_result a '
387
OK
388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403
mysqltest: At line 1: Wrong number of arguments to replace_result in 'replace_result a b c'
mysqltest: At line 1: Wrong number of arguments to replace_result in 'replace_result a b c '
select "a" as col1, "c" as col2;
col1	col2
b	c
select "a" as col1, "c" as col2;
col1	col2
b	d
mysqltest: At line 1: Wrong column number to replace_column in 'replace_column a'
mysqltest: At line 1: Wrong number of arguments to replace_column in 'replace_column 1'
mysqltest: At line 1: Wrong column number to replace_column in 'replace_column a b'
mysqltest: At line 1: Wrong column number to replace_column in 'replace_column a 1'
mysqltest: At line 1: Wrong column number to replace_column in 'replace_column 1 b c '
mysqltest: At line 1: Invalid integer argument "10!"
mysqltest: At line 1: End of line junk detected: "!"
mysqltest: At line 1: Invalid integer argument "a"
404 405 406 407 408 409 410 411 412 413 414 415
mysqltest: At line 1: Missing required argument 'connection name' to command 'connect'
mysqltest: At line 1: Missing required argument 'connection name' to command 'connect'
mysqltest: At line 1: Missing required argument 'host' to command 'connect'
mysqltest: At line 1: Missing required argument 'host' to command 'connect'
mysqltest: At line 1: query 'connect  con2,localhost,root,,illegal_db' failed: 1049: Unknown database 'illegal_db'
mysqltest: At line 1: Illegal argument for port: 'illegal_port'
mysqltest: At line 1: Illegal option to connect: SMTP
OK
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/mysqltest.sql": At line 7: Connection limit exhausted, you can have max 128 connections
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/mysqltest.sql": At line 3: connection 'test_con1' not found in connection pool
mysqltest: In included file "MYSQLTEST_VARDIR/tmp/mysqltest.sql": At line 2: Connection test_con1 already exists
connect(localhost,root,,test,MASTER_PORT,MASTER_SOCKET);
416 417 418 419
Output from mysqltest-x.inc
Output from mysqltest-x.inc
Output from mysqltest-x.inc
mysqltest: Could not open ./non_existing_file.inc: errno = 2
420 421 422 423 424 425 426
failing_statement;
ERROR 42000: 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 'failing_statement' at line 1
failing_statement;
ERROR 42000: 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 'failing_statement' at line 1
SELECT 1 as a;
a
1
427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520
select 1 as `a'b`, 2 as `a"b`;
a'b	a"b
1	2
select 'aaa\\','aa''a',"aa""a";
aaa\	aa'a	aa"a
aaa\	aa'a	aa"a

Here comes a message
--------------------

root@localhost
--------------

"Here comes a very very long message that
    - is longer then 80 characters    and
    - consists of several lines"
--------------------------------------------------------------------------------

. Here comes a very very long message that
.      - is longer then 80 characters    and
.      - consists of several lines
--------------------------------------------------------------------------------
this will be executed
this will be executed
mysqltest: Result length mismatch
mysqltest: The test didn't produce any output
Failing multi statement query
mysqltest: At line 3: query 'create table t1 (a int primary key);
insert into t1 values (1);
select 'select-me';
insertz 'error query'' failed: 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 'insertz 'error query'' at line 1
drop table t1;
mysqltest: At line 3: query 'create table t1 (a int primary key);
insert into t1 values (1);
select 'select-me';
insertz 'error query'' failed: 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 'insertz 'error query'' at line 1
drop table t1;
Multi statement using expected error
create table t1 (a int primary key);
insert into t1 values (1);
select 'select-me';
insertz error query||||
select-me
select-me
ERROR 42000: 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 'insertz error query' at line 1
drop table t1;
drop table t1;
sleep;
ERROR 42000: 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 'sleep' at line 1
sleep;
ERROR 42000: 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 'sleep' at line 1
;
ERROR 42000: Query was empty
select "b" as col1, "c" as col2;
col1	col2
b	c
select "b" as col1, "b" as col2, "c" as col3;
col1	col2	col3
b	b	c
seled "b" bs col1, "d" bs col2;
col1	col2
b	d
select "raspberry and strawberry","blackberry","tomato";
raspberry and strawberry	blackberry	tomato
raspberry and strawberry	blackberry	tomato
mysqltest: At line 1: Error parsing replace_regex "a"
mysqltest: At line 1: Error parsing replace_regex "a;"
mysqltest: At line 1: Error parsing replace_regex "a"
mysqltest: At line 1: Error parsing replace_regex "a "
mysqltest: At line 1: Error parsing replace_regex "a b"
mysqltest: At line 1: Error parsing replace_regex "/a b c"
mysqltest: At line 1: Error parsing replace_regex "/a /b c "
create table t1 (a int, b int);
insert into t1 values (1,3);
insert into t1 values (2,4);
select * from t1;
a	D
1	1
1	4
drop table t1;
mysqltest: At line 1: Missing required argument 'filename' to command 'remove_file'
mysqltest: At line 1: Missing required argument 'filename' to command 'write_file'
mysqltest: At line 1: End of file encountered before 'EOF' delimiter was found
mysqltest: At line 1: End of line junk detected: "write_file filename ";
"
mysqltest: At line 1: Missing required argument 'filename' to command 'file_exists'
mysqltest: At line 1: Missing required argument 'from_file' to command 'copy_file'
mysqltest: At line 1: Missing required argument 'to_file' to command 'copy_file'
hello
hello
hello
mysqltest: At line 1: Max delimiter length(16) exceeded
hello
hello
521 522
mysqltest: At line 1: test of die
Some output
523
End of tests