147
147
# The following should give errors
149
--error ER_UNKNOWN_SYSTEM_VARIABLE
150
150
set unknown_variable=1;
151
--error ER_WRONG_TYPE_FOR_VAR
152
152
set max_join_size="hello";
153
--error ER_UNKNOWN_STORAGE_ENGINE
154
154
set storage_engine=UNKNOWN_TABLE_TYPE;
155
--error ER_NO_DEFAULT
156
156
set GLOBAL storage_engine=DEFAULT;
157
--error ER_LOCAL_VARIABLE
158
158
set global autocommit=1;
159
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
160
160
select @@global.timestamp;
161
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
162
162
set @@version='';
163
--error ER_GLOBAL_VARIABLE
164
164
set myisam_max_sort_file_size=100;
165
--error ER_WRONG_VALUE_FOR_VAR
166
166
set @@SQL_WARNINGS=NULL;
168
168
# Test setting all variables
196
196
set tmp_table_size=100;
197
197
set tx_isolation="READ-COMMITTED";
203
create temporary table t1 (a int not null auto_increment, primary key(a));
204
create temporary table t2 (a int not null auto_increment, primary key(a));
205
insert into t1 values(null),(null),(null);
206
insert into t2 values(null),(null),(null);
207
set global myisam_key_cache_size=100000;
208
select @@myisam_key_cache_size;
209
select * from t1 where a=2;
210
select * from t2 where a=3;
212
select max(a) +1, max(a) +2 into @xx,@yy from t1;
224
select @@session.myisam_key_cache_size;
226
# init_connect was removed
228
#set init_connect = NULL;
229
#set global init_connect = NULL;
231
199
# Bug#3754 SET GLOBAL myisam_max_sort_file_size doesn't work as
232
200
# expected: check that there is no overflow when 64-bit
233
201
# variables are set
259
# Bug#2586:Disallow global/session/local as structured var. instance names
262
set @@global.global.myisam_key_cache_size= 1;
264
set GLOBAL global.myisam_key_cache_size= 1;
266
SELECT @@global.global.myisam_key_cache_size;
268
SELECT @@global.session.myisam_key_cache_size;
270
SELECT @@global.local.myisam_key_cache_size;
273
227
# BUG#4788 show create table provides incorrect statement
275
229
# What default width have numeric types?
314
268
--echo *** LC_TIME_NAMES: testing with string expressions
315
269
set lc_time_names=concat('de','_','DE');
316
270
select @@lc_time_names;
271
--error ER_UNKNOWN_ERROR
318
272
set lc_time_names=concat('de','+','DE');
319
273
select @@lc_time_names;
320
274
--echo LC_TIME_NAMES: testing with numeric expressions
321
275
set @@lc_time_names=1+2;
322
276
select @@lc_time_names;
277
--error ER_WRONG_TYPE_FOR_VAR
324
278
set @@lc_time_names=1/0;
325
279
select @@lc_time_names;
326
280
set lc_time_names=en_US;
327
281
--echo LC_TIME_NAMES: testing NULL and a negative number:
282
--error ER_WRONG_VALUE_FOR_VAR
329
283
set lc_time_names=NULL;
284
--error ER_UNKNOWN_ERROR
331
285
set lc_time_names=-1;
332
286
select @@lc_time_names;
333
287
--echo LC_TIME_NAMES: testing locale with the last ID:
334
288
set lc_time_names=108;
335
289
select @@lc_time_names;
336
290
--echo LC_TIME_NAMES: testing a number beyond the valid ID range:
291
--error ER_UNKNOWN_ERROR
338
292
set lc_time_names=109;
339
293
select @@lc_time_names;
340
294
--echo LC_TIME_NAMES: testing that 0 is en_US:
410
364
# Bug #11775 Variable character_set_system does not exist (sometimes)
366
--error ER_UNKNOWN_SYSTEM_VARIABLE
413
367
select @@character_set_system;
368
--error ER_UNKNOWN_SYSTEM_VARIABLE
415
369
set global character_set_system = utf8;
370
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
417
371
set @@global.version_compile_os='234';
420
374
# Check character_set_filesystem variable invalid for Drizzle
376
--error ER_UNKNOWN_SYSTEM_VARIABLE
423
377
set @@global.character_set_filesystem=utf8;
378
--error ER_UNKNOWN_SYSTEM_VARIABLE
425
379
set character_set_filesystem=utf8;
511
465
# Bug #19263: variables.test doesn't clean up after itself (II/II --
468
--error ER_UNKNOWN_SYSTEM_VARIABLE
515
469
set global flush_time =@my_flush_time;
516
set global myisam_key_cache_size =@my_myisam_key_cache_size;
517
470
set global max_connect_errors =@my_max_connect_errors;
518
471
set global max_heap_table_size =@my_max_heap_table_size;
519
472
set global max_join_size =@my_max_join_size;
521
474
set global max_write_lock_count =default;
523
set global myisam_data_pointer_size =@my_myisam_data_pointer_size;
524
475
set global mysql_protocol_buffer_length= @my_mysql_protocol_buffer_length;
525
476
set global server_id =@my_server_id;
526
477
set global storage_engine =@my_storage_engine;
478
--error ER_UNKNOWN_SYSTEM_VARIABLE
528
479
set global thread_cache_size =@my_thread_cache_size;
529
480
set global myisam_sort_buffer_size =@my_myisam_sort_buffer_size;
482
SHOW GLOBAL VARIABLES LIKE 'max_join_size';
483
SHOW LOCAL VARIABLES LIKE 'max_join_size';
485
set GLOBAL bulk_insert_buffer_size=DEFAULT;
486
set GLOBAL join_buffer_size=DEFAULT;
487
set GLOBAL max_allowed_packet=DEFAULT;
488
set GLOBAL max_connect_errors=DEFAULT;
489
set GLOBAL max_heap_table_size=DEFAULT;
490
set GLOBAL max_join_size=DEFAULT;
491
set GLOBAL max_sort_length=DEFAULT;
492
set GLOBAL max_write_lock_count=DEFAULT;
493
set GLOBAL myisam_sort_buffer_size=DEFAULT;
494
set GLOBAL mysql_protocol_buffer_length=DEFAULT;
495
set GLOBAL read_buffer_size=DEFAULT;
496
set GLOBAL read_rnd_buffer_size=DEFAULT;
497
set GLOBAL server_id=DEFAULT;
498
set GLOBAL sort_buffer_size=DEFAULT;
499
set GLOBAL table_open_cache=DEFAULT;
500
set GLOBAL storage_engine= @my_storage_engine;
501
set GLOBAL tmp_table_size=DEFAULT;
502
set GLOBAL tx_isolation= @my_tx_isolation;
504
set SESSION bulk_insert_buffer_size=DEFAULT;
505
set SESSION join_buffer_size=DEFAULT;
506
set SESSION max_allowed_packet=DEFAULT;
507
set SESSION max_heap_table_size=DEFAULT;
508
set SESSION max_join_size=DEFAULT;
509
set SESSION max_sort_length=DEFAULT;
510
set SESSION read_buffer_size=DEFAULT;
511
set SESSION read_rnd_buffer_size=DEFAULT;
512
set SESSION sort_buffer_size=DEFAULT;
513
set SESSION sql_big_selects=DEFAULT;
514
set SESSION sql_buffer_result=DEFAULT;
515
set SESSION sql_select_limit=DEFAULT;
516
set SESSION sql_warnings=DEFAULT;
517
set SESSION storage_engine= @my_storage_engine;
518
set SESSION tmp_table_size=DEFAULT;
519
set SESSION tx_isolation= @my_tx_isolation;
532
522
# Bug#28580 Repeatation of status variables
534
525
--replace_column 2 #
535
526
show global variables where variable_name='table_definition_cache' or Variable_name='table_lock_wait_timeout';