~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/r/variables.result

  • Committer: Brian Aker
  • Date: 2008-10-06 06:47:29 UTC
  • Revision ID: brian@tangent.org-20081006064729-2i9mhjkzyvow9xsm
RemoveĀ uint.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
drop table if exists t1,t2;
 
2
set @my_binlog_cache_size         =@@global.binlog_cache_size;
2
3
set @my_connect_timeout           =@@global.connect_timeout;
 
4
set @my_delayed_insert_timeout    =@@global.delayed_insert_timeout;
 
5
set @my_delayed_queue_size        =@@global.delayed_queue_size;
3
6
set @my_flush                     =@@global.flush;
 
7
set @my_flush_time                =@@global.flush_time;
4
8
set @my_key_buffer_size           =@@global.key_buffer_size;
 
9
set @my_max_binlog_cache_size     =@@global.max_binlog_cache_size;
 
10
set @my_max_binlog_size           =@@global.max_binlog_size;
5
11
set @my_max_connect_errors        =@@global.max_connect_errors;
 
12
set @my_max_connections           =@@global.max_connections;
 
13
set @my_max_delayed_threads       =@@global.max_delayed_threads;
6
14
set @my_max_heap_table_size       =@@global.max_heap_table_size;
 
15
set @my_max_insert_delayed_threads=@@global.max_insert_delayed_threads;
7
16
set @my_max_join_size             =@@global.max_join_size;
 
17
set @my_myisam_data_pointer_size  =@@global.myisam_data_pointer_size;
8
18
set @my_net_buffer_length         =@@global.net_buffer_length;
9
19
set @my_net_write_timeout         =@@global.net_write_timeout;
10
20
set @my_net_read_timeout          =@@global.net_read_timeout;
 
21
set @my_query_cache_limit         =@@global.query_cache_limit;
 
22
set @my_query_cache_type          =@@global.query_cache_type;
 
23
set @my_rpl_recovery_rank         =@@global.rpl_recovery_rank;
11
24
set @my_server_id                 =@@global.server_id;
12
25
set @my_slow_launch_time          =@@global.slow_launch_time;
13
26
set @my_storage_engine            =@@global.storage_engine;
 
27
set @my_thread_cache_size         =@@global.thread_cache_size;
14
28
set @`test`=1;
15
29
select @test, @`test`, @TEST, @`TEST`, @"teSt";
16
30
@test   @`test` @TEST   @`TEST` @"teSt"
64
78
select @t5;
65
79
@t5
66
80
1.23456
67
 
CREATE TABLE t1 (c_id INT NOT NULL, c_name VARCHAR(250), c_country VARCHAR(250), PRIMARY KEY(c_id));
 
81
CREATE TABLE t1 (c_id INT(4) NOT NULL, c_name CHAR(20), c_country CHAR(3), PRIMARY KEY(c_id));
68
82
INSERT INTO t1 VALUES (1,'Bozo','USA'),(2,'Ronald','USA'),(3,'Kinko','IRE'),(4,'Mr. Floppy','GB');
69
83
SELECT @min_cid:=min(c_id), @max_cid:=max(c_id) from t1;
70
84
@min_cid:=min(c_id)     @max_cid:=max(c_id)
114
128
set GLOBAL max_join_size=DEFAULT;
115
129
show global variables like 'max_join_size';
116
130
Variable_name   Value
117
 
max_join_size   2147483647
 
131
max_join_size   HA_POS_ERROR
118
132
select * from information_schema.global_variables where variable_name like 'max_join_size';
119
133
VARIABLE_NAME   VARIABLE_VALUE
120
 
MAX_JOIN_SIZE   2147483647
 
134
MAX_JOIN_SIZE   HA_POS_ERROR
121
135
set @@max_join_size=1000, @@global.max_join_size=2000;
122
136
select @@local.max_join_size, @@global.max_join_size;
123
137
@@local.max_join_size   @@global.max_join_size
144
158
1       SIMPLE  NULL    NULL    NULL    NULL    NULL    NULL    NULL    NULL    No tables used
145
159
Warnings:
146
160
Note    1003    select 345 AS `@@IDENTITY`,last_insert_id() AS `last_insert_id()`,345 AS `@@identity`
 
161
set big_tables=OFF, big_tables=ON, big_tables=0, big_tables=1, big_tables="OFF", big_tables="ON";
 
162
set global concurrent_insert=2;
 
163
show variables like 'concurrent_insert';
 
164
Variable_name   Value
 
165
concurrent_insert       2
 
166
select * from information_schema.session_variables where variable_name like 'concurrent_insert';
 
167
VARIABLE_NAME   VARIABLE_VALUE
 
168
CONCURRENT_INSERT       2
 
169
set global concurrent_insert=1;
 
170
show variables like 'concurrent_insert';
 
171
Variable_name   Value
 
172
concurrent_insert       1
 
173
select * from information_schema.session_variables where variable_name like 'concurrent_insert';
 
174
VARIABLE_NAME   VARIABLE_VALUE
 
175
CONCURRENT_INSERT       1
 
176
set global concurrent_insert=0;
 
177
show variables like 'concurrent_insert';
 
178
Variable_name   Value
 
179
concurrent_insert       0
 
180
select * from information_schema.session_variables where variable_name like 'concurrent_insert';
 
181
VARIABLE_NAME   VARIABLE_VALUE
 
182
CONCURRENT_INSERT       0
 
183
set global concurrent_insert=DEFAULT;
 
184
select @@concurrent_insert;
 
185
@@concurrent_insert
 
186
1
147
187
set global timed_mutexes=ON;
148
188
show variables like 'timed_mutexes';
149
189
Variable_name   Value
167
207
STORAGE_ENGINE  MEMORY
168
208
show global variables like 'storage_engine';
169
209
Variable_name   Value
170
 
storage_engine  InnoDB
 
210
storage_engine  MyISAM
171
211
select * from information_schema.global_variables where variable_name like 'storage_engine';
172
212
VARIABLE_NAME   VARIABLE_VALUE
173
 
STORAGE_ENGINE  InnoDB
 
213
STORAGE_ENGINE  MyISAM
 
214
set GLOBAL query_cache_size=100000;
174
215
set GLOBAL myisam_max_sort_file_size=2000000;
175
216
show global variables like 'myisam_max_sort_file_size';
176
217
Variable_name   Value
177
 
myisam_max_sort_file_size       2000000
 
218
myisam_max_sort_file_size       1048576
178
219
select * from information_schema.global_variables where variable_name like 'myisam_max_sort_file_size';
179
220
VARIABLE_NAME   VARIABLE_VALUE
180
 
MYISAM_MAX_SORT_FILE_SIZE       2000000
 
221
MYISAM_MAX_SORT_FILE_SIZE       1048576
181
222
set GLOBAL myisam_max_sort_file_size=default;
182
223
show global variables like 'myisam_max_sort_file_size';
183
224
Variable_name   Value
184
 
myisam_max_sort_file_size       2147483647
 
225
myisam_max_sort_file_size       FILE_SIZE
185
226
select * from information_schema.global_variables where variable_name like 'myisam_max_sort_file_size';
186
227
VARIABLE_NAME   VARIABLE_VALUE
187
 
MYISAM_MAX_SORT_FILE_SIZE       2147483647
 
228
MYISAM_MAX_SORT_FILE_SIZE       FILE_SIZE
188
229
set global net_retry_count=10, session net_retry_count=10;
189
230
set global net_buffer_length=1024, net_write_timeout=200, net_read_timeout=300;
190
231
set session net_buffer_length=2048, net_write_timeout=500, net_read_timeout=600;
255
296
select * from information_schema.session_variables where variable_name like 'net_buffer_length';
256
297
VARIABLE_NAME   VARIABLE_VALUE
257
298
NET_BUFFER_LENGTH       1048576
 
299
set character set cp1251_koi8;
 
300
show variables like "character_set_client";
 
301
Variable_name   Value
 
302
character_set_client    cp1251
 
303
select * from information_schema.session_variables where variable_name like 'character_set_client';
 
304
VARIABLE_NAME   VARIABLE_VALUE
 
305
CHARACTER_SET_CLIENT    cp1251
 
306
select @@timestamp>0;
 
307
@@timestamp>0
 
308
1
 
309
set @@rand_seed1=10000000,@@rand_seed2=1000000;
 
310
select ROUND(RAND(),5);
 
311
ROUND(RAND(),5)
 
312
0.02887
258
313
show variables like '%alloc%';
259
314
Variable_name   Value
260
315
query_alloc_block_size  8192
261
316
query_prealloc_size     8192
262
 
range_alloc_block_size  
 
317
range_alloc_block_size  4096
263
318
transaction_alloc_block_size    8192
264
319
transaction_prealloc_size       4096
265
320
select * from information_schema.session_variables where variable_name like '%alloc%' order by 1;
266
321
VARIABLE_NAME   VARIABLE_VALUE
267
322
QUERY_ALLOC_BLOCK_SIZE  8192
268
323
QUERY_PREALLOC_SIZE     8192
269
 
RANGE_ALLOC_BLOCK_SIZE  
 
324
RANGE_ALLOC_BLOCK_SIZE  4096
270
325
TRANSACTION_ALLOC_BLOCK_SIZE    8192
271
326
TRANSACTION_PREALLOC_SIZE       4096
272
327
set @@range_alloc_block_size=1024*16;
281
336
Variable_name   Value
282
337
query_alloc_block_size  17408
283
338
query_prealloc_size     18432
284
 
range_alloc_block_size  
 
339
range_alloc_block_size  16384
285
340
transaction_alloc_block_size    19456
286
341
transaction_prealloc_size       20480
287
342
select * from information_schema.session_variables where variable_name like '%alloc%' order by 1;
288
343
VARIABLE_NAME   VARIABLE_VALUE
289
344
QUERY_ALLOC_BLOCK_SIZE  17408
290
345
QUERY_PREALLOC_SIZE     18432
291
 
RANGE_ALLOC_BLOCK_SIZE  
 
346
RANGE_ALLOC_BLOCK_SIZE  16384
292
347
TRANSACTION_ALLOC_BLOCK_SIZE    19456
293
348
TRANSACTION_PREALLOC_SIZE       20480
294
349
set @@range_alloc_block_size=default;
298
353
Variable_name   Value
299
354
query_alloc_block_size  8192
300
355
query_prealloc_size     8192
301
 
range_alloc_block_size  
 
356
range_alloc_block_size  4096
302
357
transaction_alloc_block_size    8192
303
358
transaction_prealloc_size       4096
304
359
select * from information_schema.session_variables where variable_name like '%alloc%' order by 1;
305
360
VARIABLE_NAME   VARIABLE_VALUE
306
361
QUERY_ALLOC_BLOCK_SIZE  8192
307
362
QUERY_PREALLOC_SIZE     8192
308
 
RANGE_ALLOC_BLOCK_SIZE  
 
363
RANGE_ALLOC_BLOCK_SIZE  4096
309
364
TRANSACTION_ALLOC_BLOCK_SIZE    8192
310
365
TRANSACTION_PREALLOC_SIZE       4096
311
366
SELECT @@version LIKE 'non-existent';
314
369
SELECT @@version_compile_os LIKE 'non-existent';
315
370
@@version_compile_os LIKE 'non-existent'
316
371
0
 
372
set big_tables=OFFF;
 
373
ERROR 42000: Variable 'big_tables' can't be set to the value of 'OFFF'
 
374
set big_tables="OFFF";
 
375
ERROR 42000: Variable 'big_tables' can't be set to the value of 'OFFF'
317
376
set unknown_variable=1;
318
377
ERROR HY000: Unknown system variable 'unknown_variable'
319
378
set max_join_size="hello";
320
379
ERROR 42000: Incorrect argument type to variable 'max_join_size'
321
380
set storage_engine=UNKNOWN_TABLE_TYPE;
322
381
ERROR 42000: Unknown table engine 'UNKNOWN_TABLE_TYPE'
 
382
set SESSION query_cache_size=10000;
 
383
ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL
323
384
set GLOBAL storage_engine=DEFAULT;
324
385
ERROR 42000: Variable 'storage_engine' doesn't have a default value
 
386
set character_set_client=UNKNOWN_CHARACTER_SET;
 
387
ERROR 42000: Unknown character set: 'UNKNOWN_CHARACTER_SET'
 
388
set collation_connection=UNKNOWN_COLLATION;
 
389
ERROR HY000: Unknown collation: 'UNKNOWN_COLLATION'
 
390
set character_set_client=NULL;
 
391
ERROR 42000: Variable 'character_set_client' can't be set to the value of 'NULL'
 
392
set collation_connection=NULL;
 
393
ERROR 42000: Variable 'collation_connection' can't be set to the value of 'NULL'
325
394
set global autocommit=1;
326
395
ERROR HY000: Variable 'autocommit' is a SESSION variable and can't be used with SET GLOBAL
327
396
select @@global.timestamp;
328
397
ERROR HY000: Variable 'timestamp' is a SESSION variable
329
398
set @@version='';
330
399
ERROR HY000: Variable 'version' is a read only variable
 
400
set @@concurrent_insert=1;
 
401
ERROR HY000: Variable 'concurrent_insert' is a GLOBAL variable and should be set with SET GLOBAL
 
402
set @@global.sql_auto_is_null=1;
 
403
ERROR HY000: Variable 'sql_auto_is_null' is a SESSION variable and can't be used with SET GLOBAL
 
404
select @@global.sql_auto_is_null;
 
405
ERROR HY000: Variable 'sql_auto_is_null' is a SESSION variable
331
406
set myisam_max_sort_file_size=100;
332
407
ERROR HY000: Variable 'myisam_max_sort_file_size' is a GLOBAL variable and should be set with SET GLOBAL
333
408
set @@SQL_WARNINGS=NULL;
334
409
ERROR 42000: Variable 'sql_warnings' can't be set to the value of 'NULL'
335
410
set autocommit=1;
336
 
select @@autocommit;
337
 
@@autocommit
338
 
1
 
411
set big_tables=1;
 
412
select @@autocommit, @@big_tables;
 
413
@@autocommit    @@big_tables
 
414
1       1
 
415
set global binlog_cache_size=100;
 
416
Warnings:
 
417
Warning 1292    Truncated incorrect binlog_cache_size value: '100'
339
418
set bulk_insert_buffer_size=100;
 
419
set character set cp1251_koi8;
 
420
set character set default;
 
421
set @@global.concurrent_insert=1;
340
422
set global connect_timeout=100;
341
423
select @@delay_key_write;
342
424
@@delay_key_write
346
428
@@delay_key_write
347
429
OFF
348
430
set global delay_key_write=ALL;
 
431
select @@delay_key_write;
 
432
@@delay_key_write
 
433
ALL
349
434
set global delay_key_write=1;
350
435
select @@delay_key_write;
351
436
@@delay_key_write
352
437
ON
 
438
set global delayed_insert_limit=100;
 
439
set global delayed_insert_timeout=100;
 
440
set global delayed_queue_size=100;
 
441
set global flush=1;
 
442
set global flush_time=100;
 
443
set insert_id=1;
353
444
set interactive_timeout=100;
354
445
set join_buffer_size=100;
355
446
Warnings:
356
447
Warning 1292    Truncated incorrect join_buffer_size value: '100'
357
448
set last_insert_id=1;
358
449
set global local_infile=1;
 
450
set long_query_time=0.000001;
 
451
select @@long_query_time;
 
452
@@long_query_time
 
453
0.000001
 
454
set long_query_time=100.000001;
 
455
select @@long_query_time;
 
456
@@long_query_time
 
457
100.000001
 
458
set low_priority_updates=1;
359
459
set max_allowed_packet=100;
360
460
Warnings:
361
461
Warning 1292    Truncated incorrect max_allowed_packet value: '100'
 
462
set global max_binlog_cache_size=100;
 
463
Warnings:
 
464
Warning 1292    Truncated incorrect max_binlog_cache_size value: '100'
 
465
set global max_binlog_size=100;
 
466
Warnings:
 
467
Warning 1292    Truncated incorrect max_binlog_size value: '100'
362
468
set global max_connect_errors=100;
 
469
set global max_connections=100;
 
470
set global max_delayed_threads=100;
363
471
set max_heap_table_size=100;
364
472
Warnings:
365
473
Warning 1292    Truncated incorrect max_heap_table_size value: '100'
366
474
set max_join_size=100;
367
475
set max_sort_length=100;
368
476
set max_tmp_tables=100;
 
477
set global max_user_connections=100;
 
478
select @@max_user_connections;
 
479
@@max_user_connections
 
480
100
369
481
set global max_write_lock_count=100;
370
 
set global myisam_sort_buffer_size=100;
371
 
Warnings:
372
 
Warning 1292    Truncated incorrect sort_buffer_size value: '100'
 
482
set myisam_sort_buffer_size=100;
373
483
set net_buffer_length=100;
374
484
Warnings:
375
485
Warning 1292    Truncated incorrect net_buffer_length value: '100'
376
486
set net_read_timeout=100;
377
487
set net_write_timeout=100;
 
488
set global query_cache_limit=100;
 
489
set global query_cache_size=100;
 
490
set global query_cache_type=demand;
378
491
set read_buffer_size=100;
379
492
Warnings:
380
493
Warning 1292    Truncated incorrect read_buffer_size value: '100'
381
494
set read_rnd_buffer_size=100;
 
495
set global rpl_recovery_rank=100;
382
496
set global server_id=100;
383
497
set global slow_launch_time=100;
384
498
set sort_buffer_size=100;
385
499
Warnings:
386
500
Warning 1292    Truncated incorrect sort_buffer_size value: '100'
 
501
set @@max_sp_recursion_depth=10;
 
502
select @@max_sp_recursion_depth;
 
503
@@max_sp_recursion_depth
 
504
10
 
505
set @@max_sp_recursion_depth=0;
 
506
select @@max_sp_recursion_depth;
 
507
@@max_sp_recursion_depth
 
508
0
 
509
set sql_auto_is_null=1;
 
510
select @@sql_auto_is_null;
 
511
@@sql_auto_is_null
 
512
1
 
513
set @@sql_auto_is_null=0;
 
514
select @@sql_auto_is_null;
 
515
@@sql_auto_is_null
 
516
0
387
517
set sql_big_selects=1;
 
518
set sql_big_tables=1;
388
519
set sql_buffer_result=1;
 
520
set sql_log_bin=1;
 
521
set sql_log_off=1;
 
522
set sql_log_update=1;
 
523
Warnings:
 
524
Note    1315    The update log is deprecated and replaced by the binary log; SET SQL_LOG_UPDATE has been ignored
 
525
set sql_low_priority_updates=1;
 
526
set sql_max_join_size=200;
 
527
select @@sql_max_join_size,@@max_join_size;
 
528
@@sql_max_join_size     @@max_join_size
 
529
200     200
 
530
set sql_quote_show_create=1;
389
531
set sql_safe_updates=1;
390
532
set sql_select_limit=1;
391
533
set sql_select_limit=default;
392
534
set sql_warnings=1;
393
535
set global table_open_cache=100;
394
536
set storage_engine=myisam;
 
537
set global thread_cache_size=100;
395
538
set timestamp=1, timestamp=default;
396
539
set tmp_table_size=100;
397
540
Warnings:
398
541
Warning 1292    Truncated incorrect tmp_table_size value: '100'
399
542
set tx_isolation="READ-COMMITTED";
400
543
set wait_timeout=100;
 
544
set log_warnings=1;
 
545
set global log_warnings=1;
 
546
select @@session.insert_id;
 
547
@@session.insert_id
 
548
1
 
549
set @save_insert_id=@@session.insert_id;
 
550
set session insert_id=20;
 
551
select @@session.insert_id;
 
552
@@session.insert_id
 
553
20
 
554
set session last_insert_id=100;
 
555
select @@session.insert_id;
 
556
@@session.insert_id
 
557
20
 
558
select @@session.last_insert_id;
 
559
@@session.last_insert_id
 
560
100
 
561
select @@session.insert_id;
 
562
@@session.insert_id
 
563
20
 
564
set @@session.insert_id=@save_insert_id;
 
565
select @@session.insert_id;
 
566
@@session.insert_id
 
567
1
401
568
create table t1 (a int not null auto_increment, primary key(a));
402
569
create table t2 (a int not null auto_increment, primary key(a));
403
570
insert into t1 values(null),(null),(null);
436
603
VARIABLE_NAME   VARIABLE_VALUE
437
604
MYISAM_MAX_SORT_FILE_SIZE       MAX_FILE_SIZE
438
605
set global myisam_max_sort_file_size=default;
 
606
select @@global.max_user_connections,@@local.max_join_size;
 
607
@@global.max_user_connections   @@local.max_join_size
 
608
100     200
 
609
set @svc=@@global.max_user_connections, @svj=@@local.max_join_size;
 
610
select @@global.max_user_connections,@@local.max_join_size;
 
611
@@global.max_user_connections   @@local.max_join_size
 
612
100     200
 
613
set @@global.max_user_connections=111,@@local.max_join_size=222;
 
614
select @@global.max_user_connections,@@local.max_join_size;
 
615
@@global.max_user_connections   @@local.max_join_size
 
616
111     222
 
617
set @@global.max_user_connections=@@local.max_join_size,@@local.max_join_size=@@global.max_user_connections;
 
618
select @@global.max_user_connections,@@local.max_join_size;
 
619
@@global.max_user_connections   @@local.max_join_size
 
620
222     111
 
621
set @@global.max_user_connections=@svc, @@local.max_join_size=@svj;
 
622
select @@global.max_user_connections,@@local.max_join_size;
 
623
@@global.max_user_connections   @@local.max_join_size
 
624
100     200
 
625
set @a=1, @b=2;
 
626
set @a=@b, @b=@a;
 
627
select @a, @b;
 
628
@a      @b
 
629
2       1
439
630
set @@global.global.key_buffer_size= 1;
440
 
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near 'key_buffer_size= 1' at line 1
 
631
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 'key_buffer_size= 1' at line 1
441
632
set GLOBAL global.key_buffer_size= 1;
442
 
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near 'key_buffer_size= 1' at line 1
 
633
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 'key_buffer_size= 1' at line 1
443
634
SELECT @@global.global.key_buffer_size;
444
 
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near 'key_buffer_size' at line 1
 
635
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 'key_buffer_size' at line 1
445
636
SELECT @@global.session.key_buffer_size;
446
 
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near 'key_buffer_size' at line 1
 
637
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 'key_buffer_size' at line 1
447
638
SELECT @@global.local.key_buffer_size;
448
 
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near 'key_buffer_size' at line 1
 
639
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 'key_buffer_size' at line 1
 
640
set @tstlw = @@log_warnings;
 
641
show global variables like 'log_warnings';
 
642
Variable_name   Value
 
643
log_warnings    1
 
644
select * from information_schema.global_variables where variable_name like 'log_warnings';
 
645
VARIABLE_NAME   VARIABLE_VALUE
 
646
LOG_WARNINGS    1
 
647
set global log_warnings = 0;
 
648
show global variables like 'log_warnings';
 
649
Variable_name   Value
 
650
log_warnings    0
 
651
select * from information_schema.global_variables where variable_name like 'log_warnings';
 
652
VARIABLE_NAME   VARIABLE_VALUE
 
653
LOG_WARNINGS    0
 
654
set global log_warnings = 42;
 
655
show global variables like 'log_warnings';
 
656
Variable_name   Value
 
657
log_warnings    42
 
658
select * from information_schema.global_variables where variable_name like 'log_warnings';
 
659
VARIABLE_NAME   VARIABLE_VALUE
 
660
LOG_WARNINGS    42
 
661
set global log_warnings = @tstlw;
 
662
show global variables like 'log_warnings';
 
663
Variable_name   Value
 
664
log_warnings    1
 
665
select * from information_schema.global_variables where variable_name like 'log_warnings';
 
666
VARIABLE_NAME   VARIABLE_VALUE
 
667
LOG_WARNINGS    1
449
668
create table t1 (
450
 
c1 int,
451
 
c2 int,
452
 
c3 int,
 
669
c1 tinyint,
 
670
c2 smallint,
 
671
c3 mediumint,
453
672
c4 int,
454
673
c5 bigint);
455
674
show create table t1;
456
675
Table   Create Table
457
676
t1      CREATE TABLE `t1` (
458
 
  `c1` int,
459
 
  `c2` int,
460
 
  `c3` int,
461
 
  `c4` int,
462
 
  `c5` bigint
463
 
) ENGINE=MyISAM
 
677
  `c1` tinyint(4) DEFAULT NULL,
 
678
  `c2` smallint(6) DEFAULT NULL,
 
679
  `c3` mediumint(9) DEFAULT NULL,
 
680
  `c4` int(11) DEFAULT NULL,
 
681
  `c5` bigint(20) DEFAULT NULL
 
682
) ENGINE=MyISAM DEFAULT CHARSET=latin1
464
683
drop table t1;
465
684
set @arg00= 8, @arg01= 8.8, @arg02= 'a string', @arg03= 0.2e0;
466
685
create table t1 as select @arg00 as c1, @arg01 as c2, @arg02 as c3, @arg03 as c4;
467
686
show create table t1;
468
687
Table   Create Table
469
688
t1      CREATE TABLE `t1` (
470
 
  `c1` bigint,
471
 
  `c2` decimal(65,30),
472
 
  `c3` text,
473
 
  `c4` double
474
 
) ENGINE=MyISAM
 
689
  `c1` bigint(20) DEFAULT NULL,
 
690
  `c2` decimal(65,30) DEFAULT NULL,
 
691
  `c3` longtext,
 
692
  `c4` double DEFAULT NULL
 
693
) ENGINE=MyISAM DEFAULT CHARSET=latin1
475
694
drop table t1;
 
695
SET GLOBAL MYISAM_DATA_POINTER_SIZE= 7;
 
696
SHOW VARIABLES LIKE 'MYISAM_DATA_POINTER_SIZE';
 
697
Variable_name   Value
 
698
myisam_data_pointer_size        7
 
699
SELECT * FROM INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME LIKE 'MYISAM_DATA_POINTER_SIZE';
 
700
VARIABLE_NAME   VARIABLE_VALUE
 
701
MYISAM_DATA_POINTER_SIZE        7
476
702
SET GLOBAL table_open_cache=-1;
477
703
Warnings:
478
704
Warning 1292    Truncated incorrect table_open_cache value: '0'
479
705
SHOW VARIABLES LIKE 'table_open_cache';
480
706
Variable_name   Value
481
707
table_open_cache        1
 
708
SELECT * FROM INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME LIKE 'table_open_cache';
 
709
VARIABLE_NAME   VARIABLE_VALUE
 
710
TABLE_OPEN_CACHE        1
482
711
SET GLOBAL table_open_cache=DEFAULT;
 
712
set character_set_results=NULL;
 
713
select ifnull(@@character_set_results,"really null");
 
714
ifnull(@@character_set_results,"really null")
 
715
really null
 
716
set names latin1;
 
717
select @@have_innodb;
 
718
@@have_innodb
 
719
#
483
720
*** Various tests with LC_TIME_NAMES
484
721
*** LC_TIME_NAMES: testing case insensitivity
485
722
set @@lc_time_names='ru_ru';
573
810
select @@query_prealloc_size = @test;
574
811
@@query_prealloc_size = @test
575
812
1
 
813
set global sql_mode=repeat('a',80);
 
814
ERROR 42000: Variable 'sql_mode' can't be set to the value of 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'
576
815
End of 4.1 tests
577
816
create table t1 (a int);
578
817
select a into @x from t1;
599
838
@@max_heap_table_size > 0
600
839
1
601
840
select @@character_set_system;
602
 
ERROR HY000: Unknown system variable 'character_set_system'
603
 
set global character_set_system = utf8;
604
 
ERROR HY000: Unknown system variable 'character_set_system'
 
841
@@character_set_system
 
842
utf8
 
843
set global character_set_system = latin1;
 
844
ERROR HY000: Variable 'character_set_system' is a read only variable
605
845
set @@global.version_compile_os='234';
606
846
ERROR HY000: Variable 'version_compile_os' is a read only variable
607
 
set @@global.character_set_filesystem=utf8;
608
 
ERROR HY000: Unknown system variable 'character_set_filesystem'
609
 
set character_set_filesystem=utf8;
610
 
ERROR HY000: Unknown system variable 'character_set_filesystem'
 
847
set character_set_filesystem=latin1;
 
848
select @@character_set_filesystem;
 
849
@@character_set_filesystem
 
850
latin1
 
851
set @@global.character_set_filesystem=latin2;
 
852
set character_set_filesystem=latin1;
 
853
select @@character_set_filesystem;
 
854
@@character_set_filesystem
 
855
latin1
 
856
set @@global.character_set_filesystem=latin2;
 
857
set character_set_filesystem=default;
 
858
select @@character_set_filesystem;
 
859
@@character_set_filesystem
 
860
latin2
 
861
set @@global.character_set_filesystem=default;
 
862
select @@global.character_set_filesystem;
 
863
@@global.character_set_filesystem
 
864
binary
611
865
set @old_sql_big_selects = @@sql_big_selects;
612
866
set @@sql_big_selects = 1;
613
867
show variables like 'sql_big_selects';
614
868
Variable_name   Value
615
869
sql_big_selects ON
 
870
select * from information_schema.session_variables where variable_name like 'sql_big_selects';
 
871
VARIABLE_NAME   VARIABLE_VALUE
 
872
SQL_BIG_SELECTS ON
616
873
set @@sql_big_selects = @old_sql_big_selects;
617
874
set @@sql_notes = 0, @@sql_warnings = 0;
618
875
show variables like 'sql_notes';
619
876
Variable_name   Value
620
877
sql_notes       OFF
 
878
select * from information_schema.session_variables where variable_name like 'sql_notes';
 
879
VARIABLE_NAME   VARIABLE_VALUE
 
880
SQL_NOTES       OFF
621
881
show variables like 'sql_warnings';
622
882
Variable_name   Value
623
883
sql_warnings    OFF
 
884
select * from information_schema.session_variables where variable_name like 'sql_warnings';
 
885
VARIABLE_NAME   VARIABLE_VALUE
 
886
SQL_WARNINGS    OFF
624
887
set @@sql_notes = 1, @@sql_warnings = 1;
625
888
show variables like 'sql_notes';
626
889
Variable_name   Value
627
890
sql_notes       ON
 
891
select * from information_schema.session_variables where variable_name like 'sql_notes';
 
892
VARIABLE_NAME   VARIABLE_VALUE
 
893
SQL_NOTES       ON
628
894
show variables like 'sql_warnings';
629
895
Variable_name   Value
630
896
sql_warnings    ON
 
897
select * from information_schema.session_variables where variable_name like 'sql_warnings';
 
898
VARIABLE_NAME   VARIABLE_VALUE
 
899
SQL_WARNINGS    ON
631
900
select @@system_time_zone;
632
901
@@system_time_zone
633
902
#
641
910
show variables like 'basedir';
642
911
Variable_name   Value
643
912
basedir #
 
913
select * from information_schema.session_variables where variable_name like 'basedir';
 
914
VARIABLE_NAME   VARIABLE_VALUE
 
915
BASEDIR #
644
916
show variables like 'datadir';
645
917
Variable_name   Value
646
918
datadir #
 
919
select * from information_schema.session_variables where variable_name like 'datadir';
 
920
VARIABLE_NAME   VARIABLE_VALUE
 
921
DATADIR #
647
922
show variables like 'tmpdir';
648
923
Variable_name   Value
649
924
tmpdir  #
 
925
select * from information_schema.session_variables where variable_name like 'tmpdir';
 
926
VARIABLE_NAME   VARIABLE_VALUE
 
927
TMPDIR  #
 
928
select @@ssl_ca, @@ssl_capath, @@ssl_cert, @@ssl_cipher, @@ssl_key;
 
929
@@ssl_ca        @@ssl_capath    @@ssl_cert      @@ssl_cipher    @@ssl_key
 
930
#       #       #       #       #
 
931
show variables like 'ssl%';
 
932
Variable_name   Value
 
933
ssl_ca  #
 
934
ssl_capath      #
 
935
ssl_cert        #
 
936
ssl_cipher      #
 
937
ssl_key #
 
938
select * from information_schema.session_variables where variable_name like 'ssl%' order by 1;
 
939
VARIABLE_NAME   VARIABLE_VALUE
 
940
SSL_CA  #
 
941
SSL_CAPATH      #
 
942
SSL_CERT        #
 
943
SSL_CIPHER      #
 
944
SSL_KEY #
 
945
select @@log_queries_not_using_indexes;
 
946
@@log_queries_not_using_indexes
 
947
0
 
948
show variables like 'log_queries_not_using_indexes';
 
949
Variable_name   Value
 
950
log_queries_not_using_indexes   OFF
 
951
select * from information_schema.session_variables where variable_name like 'log_queries_not_using_indexes';
 
952
VARIABLE_NAME   VARIABLE_VALUE
 
953
LOG_QUERIES_NOT_USING_INDEXES   OFF
650
954
select @@"";
651
 
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near '""' at line 1
 
955
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 '""' at line 1
652
956
select @@&;
653
 
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near '&' at line 1
 
957
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 '&' at line 1
654
958
select @@@;
655
 
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near '@' at line 1
 
959
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 '@' at line 1
656
960
select @@hostname;
657
961
@@hostname
658
962
#
662
966
Variable_name   Value
663
967
hostname        #
664
968
End of 5.0 tests
 
969
set global binlog_cache_size         =@my_binlog_cache_size;
665
970
set global connect_timeout           =@my_connect_timeout;
 
971
set global delayed_insert_timeout    =@my_delayed_insert_timeout;
 
972
set global delayed_queue_size        =@my_delayed_queue_size;
666
973
set global flush                     =@my_flush;
667
974
set global flush_time                =@my_flush_time;
668
 
ERROR HY000: Unknown system variable 'flush_time'
669
975
set global key_buffer_size           =@my_key_buffer_size;
 
976
set global max_binlog_cache_size     =default;
 
977
set global max_binlog_size           =@my_max_binlog_size;
670
978
set global max_connect_errors        =@my_max_connect_errors;
 
979
set global max_connections           =@my_max_connections;
 
980
set global max_delayed_threads       =@my_max_delayed_threads;
671
981
set global max_heap_table_size       =@my_max_heap_table_size;
 
982
set global max_insert_delayed_threads=@my_max_insert_delayed_threads;
672
983
set global max_join_size             =@my_max_join_size;
 
984
set global max_user_connections      =default;
673
985
set global max_write_lock_count      =default;
674
986
set global myisam_data_pointer_size  =@my_myisam_data_pointer_size;
675
 
ERROR 42000: Incorrect argument type to variable 'myisam_data_pointer_size'
676
987
set global net_buffer_length         =@my_net_buffer_length;
677
988
set global net_write_timeout         =@my_net_write_timeout;
678
989
set global net_read_timeout          =@my_net_read_timeout;
 
990
set global query_cache_limit         =@my_query_cache_limit;
 
991
set global query_cache_type          =@my_query_cache_type;
 
992
set global rpl_recovery_rank         =@my_rpl_recovery_rank;
679
993
set global server_id                 =@my_server_id;
680
994
set global slow_launch_time          =@my_slow_launch_time;
681
995
set global storage_engine            =@my_storage_engine;
682
996
set global thread_cache_size         =@my_thread_cache_size;
683
 
ERROR HY000: Unknown system variable 'thread_cache_size'
 
997
show global variables where Variable_name='table_definition_cache' or
 
998
Variable_name='table_lock_wait_timeout';
 
999
Variable_name   Value
 
1000
table_definition_cache  #
 
1001
table_lock_wait_timeout #
 
1002
 
 
1003
# --
 
1004
# -- Bug#34820: log_output can be set to illegal value.
 
1005
# --
 
1006
SET GLOBAL log_output = '';
 
1007
ERROR 42000: Variable 'log_output' can't be set to the value of ''
 
1008
SET GLOBAL log_output = 0;
 
1009
ERROR 42000: Variable 'log_output' can't be set to the value of '0'
 
1010
 
 
1011
# -- End of Bug#34820.