~drizzle-trunk/drizzle/development

1 by brian
clean slate
1
#
2
# test variables
3
#
4
--disable_warnings
5
drop table if exists t1,t2;
6
--enable_warnings
7
8
#
9
# Bug #19263: variables.test doesn't clean up after itself (I/II -- save)
10
#
1251.2.2 by Jay Pipes
Pulls MyISAM-specific server variables into the MyISAM
11
set @my_myisam_key_cache_size           =@@global.myisam_key_cache_size;
1 by brian
clean slate
12
set @my_max_connect_errors        =@@global.max_connect_errors;
13
set @my_max_heap_table_size       =@@global.max_heap_table_size;
14
set @my_max_join_size             =@@global.max_join_size;
971.7.11 by Eric Day
Fixed header file guards and fixed test cases.
15
set @my_drizzle_protocol_buffer_length =@@global.drizzle_protocol_buffer_length;
1 by brian
clean slate
16
set @my_server_id                 =@@global.server_id;
17
set @my_storage_engine            =@@global.storage_engine;
1119.4.7 by Stewart Smith
make variables test not leave state of server in a modified state. i.e. fully
18
set @my_myisam_sort_buffer_size	  =@@global.myisam_sort_buffer_size;
1 by brian
clean slate
19
20
# case insensitivity tests (new in 5.0)
21
set @`test`=1;
22
select @test, @`test`, @TEST, @`TEST`, @"teSt";
23
set @TEST=2;
24
select @test, @`test`, @TEST, @`TEST`, @"teSt";
25
set @"tEST"=3;
26
select @test, @`test`, @TEST, @`TEST`, @"teSt";
27
set @`TeST`=4;
28
select @test, @`test`, @TEST, @`TEST`, @"teSt";
29
select @`teST`:=5;
30
select @test, @`test`, @TEST, @`TEST`, @"teSt";
31
32
set @select=2,@t5=1.23456;
33
select @`select`,@not_used;
34
set @test_int=10,@test_double=1e-10,@test_string="abcdeghi",@test_string2="abcdefghij",@select=NULL;
35
# Expected result "1e-10", windows returns "1e-010"
36
--replace_result 1e-010 1e-10
37
select @test_int,@test_double,@test_string,@test_string2,@select;
38
set @test_int="hello",@test_double="hello",@test_string="hello",@test_string2="hello";
39
select @test_int,@test_double,@test_string,@test_string2;
40
set @test_int="hellohello",@test_double="hellohello",@test_string="hellohello",@test_string2="hellohello";
41
select @test_int,@test_double,@test_string,@test_string2;
42
set @test_int=null,@test_double=null,@test_string=null,@test_string2=null;
43
select @test_int,@test_double,@test_string,@test_string2;
44
select @t1:=(@t2:=1)+@t3:=4,@t1,@t2,@t3;
45
explain extended select @t1:=(@t2:=1)+@t3:=4,@t1,@t2,@t3;
46
select @t5;
47
48
#
49
# Test problem with WHERE and variables
50
#
51
620 by Brian Aker
Remove dead rand structures
52
CREATE TABLE t1 (c_id INT NOT NULL, c_name VARCHAR(250), c_country VARCHAR(250), PRIMARY KEY(c_id));
1 by brian
clean slate
53
INSERT INTO t1 VALUES (1,'Bozo','USA'),(2,'Ronald','USA'),(3,'Kinko','IRE'),(4,'Mr. Floppy','GB');
54
SELECT @min_cid:=min(c_id), @max_cid:=max(c_id) from t1;
55
SELECT * FROM t1 WHERE c_id=@min_cid OR c_id=@max_cid;
56
SELECT * FROM t1 WHERE c_id=@min_cid OR c_id=@max_cid OR c_id=666;
57
ALTER TABLE t1 DROP PRIMARY KEY;
58
select * from t1 where c_id=@min_cid OR c_id=@max_cid;
59
drop table t1;
60
61
#
62
# Test system variables
63
#
64
set GLOBAL max_join_size=10;
65
set max_join_size=100;
66
show variables like 'max_join_size';
67
select * from information_schema.session_variables where variable_name like 'max_join_size';
68
--replace_result 18446744073709551615 HA_POS_ERROR 4294967295 HA_POS_ERROR
69
show global variables like 'max_join_size';
70
--replace_result 18446744073709551615 HA_POS_ERROR 4294967295 HA_POS_ERROR
71
select * from information_schema.global_variables where variable_name like 'max_join_size';
72
set GLOBAL max_join_size=2000;
73
show global variables like 'max_join_size';
74
select * from information_schema.global_variables where variable_name like 'max_join_size';
75
set max_join_size=DEFAULT;
76
--replace_result 18446744073709551615 HA_POS_ERROR 4294967295 HA_POS_ERROR
77
show variables like 'max_join_size';
78
--replace_result 18446744073709551615 HA_POS_ERROR 4294967295 HA_POS_ERROR
79
select * from information_schema.session_variables where variable_name like 'max_join_size';
80
set GLOBAL max_join_size=DEFAULT;
81
--replace_result 18446744073709551615 HA_POS_ERROR 4294967295 HA_POS_ERROR
82
show global variables like 'max_join_size';
83
--replace_result 18446744073709551615 HA_POS_ERROR 4294967295 HA_POS_ERROR
84
select * from information_schema.global_variables where variable_name like 'max_join_size';
85
set @@max_join_size=1000, @@global.max_join_size=2000;
86
select @@local.max_join_size, @@global.max_join_size;
87
select @@identity,  length(@@version)>0;
88
select @@VERSION=version();
89
select last_insert_id(345);
90
explain extended select last_insert_id(345);
91
select @@IDENTITY,last_insert_id(), @@identity;
92
explain extended select @@IDENTITY,last_insert_id(), @@identity;
93
94
set global timed_mutexes=ON;
95
show variables like 'timed_mutexes';
96
select * from information_schema.session_variables where variable_name like 'timed_mutexes';
97
set global timed_mutexes=0;
98
show variables like 'timed_mutexes';
99
select * from information_schema.session_variables where variable_name like 'timed_mutexes';
100
1233.2.1 by Monty Taylor
Renamed instances of HEAP engine to MEMORY. Removed the alias.
101
set storage_engine=MYISAM, storage_engine="MEMORY";
1 by brian
clean slate
102
show local variables like 'storage_engine';
103
select * from information_schema.session_variables where variable_name like 'storage_engine';
104
show global variables like 'storage_engine';
105
select * from information_schema.global_variables where variable_name like 'storage_engine';
106
107
set GLOBAL myisam_max_sort_file_size=2000000;
108
show global variables like 'myisam_max_sort_file_size';
109
select * from information_schema.global_variables where variable_name like 'myisam_max_sort_file_size';
110
set GLOBAL myisam_max_sort_file_size=default;
111
--replace_result 9223372036853727232 FILE_SIZE 2146435072 FILE_SIZE
112
show global variables like 'myisam_max_sort_file_size';
113
--replace_result 9223372036853727232 FILE_SIZE 2146435072 FILE_SIZE
114
select * from information_schema.global_variables where variable_name like 'myisam_max_sort_file_size';
115
971.7.11 by Eric Day
Fixed header file guards and fixed test cases.
116
set global drizzle_protocol_buffer_length=1024;
117
show global variables like 'drizzle_protocol_buffer_%';
1225.1.23 by Padraig O'Sullivan
Removed a redundant order by in the variables test case and also updated its result file.
118
select * from information_schema.global_variables where variable_name like 'drizzle_protocol_buffer_%';
971.7.11 by Eric Day
Fixed header file guards and fixed test cases.
119
show global variables like 'drizzle_protocol_buffer_%';
1225.1.23 by Padraig O'Sullivan
Removed a redundant order by in the variables test case and also updated its result file.
120
select * from information_schema.global_variables where variable_name like 'drizzle_protocol_buffer_%';
971.7.11 by Eric Day
Fixed header file guards and fixed test cases.
121
set global drizzle_protocol_buffer_length=1;
122
show variables like 'drizzle_protocol_buffer_length';
971.7.3 by Eric Day
Added net_buffer_length tests back in as oldlibdrizzle_buffer_length tests.
123
#warning 1292
971.7.11 by Eric Day
Fixed header file guards and fixed test cases.
124
set global drizzle_protocol_buffer_length=2000000000;
125
show variables like 'drizzle_protocol_buffer_length';
971.7.3 by Eric Day
Added net_buffer_length tests back in as oldlibdrizzle_buffer_length tests.
126
1 by brian
clean slate
127
show variables like '%alloc%';
1225.1.23 by Padraig O'Sullivan
Removed a redundant order by in the variables test case and also updated its result file.
128
select * from information_schema.session_variables where variable_name like '%alloc%';
1 by brian
clean slate
129
set @@range_alloc_block_size=1024*16;
130
set @@query_alloc_block_size=1024*17+2;
131
set @@query_prealloc_size=1024*18;
132
set @@transaction_alloc_block_size=1024*20-1;
133
set @@transaction_prealloc_size=1024*21-1;
134
select @@query_alloc_block_size;
135
show variables like '%alloc%';
1225.1.23 by Padraig O'Sullivan
Removed a redundant order by in the variables test case and also updated its result file.
136
select * from information_schema.session_variables where variable_name like '%alloc%';
1 by brian
clean slate
137
set @@range_alloc_block_size=default;
138
set @@query_alloc_block_size=default, @@query_prealloc_size=default;
139
set transaction_alloc_block_size=default, @@transaction_prealloc_size=default;
140
show variables like '%alloc%';
1225.1.23 by Padraig O'Sullivan
Removed a redundant order by in the variables test case and also updated its result file.
141
select * from information_schema.session_variables where variable_name like '%alloc%';
1 by brian
clean slate
142
143
#
144
# Bug #10904 Illegal mix of collations between
145
# a system variable and a constant
146
#
147
SELECT @@version LIKE 'non-existent';
148
SELECT @@version_compile_os LIKE 'non-existent';
149
150
# The following should give errors
151
152
--error 1193
153
set unknown_variable=1;
154
--error 1232
155
set max_join_size="hello";
156
--error 1286
157
set storage_engine=UNKNOWN_TABLE_TYPE;
158
--error 1230
159
set GLOBAL storage_engine=DEFAULT;
160
--error 1228
161
set global autocommit=1;
162
--error 1238
163
select @@global.timestamp;
164
--error 1238 
165
set @@version='';
166
--error 1229
167
set myisam_max_sort_file_size=100;
168
--error 1231
169
set @@SQL_WARNINGS=NULL;
170
171
# Test setting all variables
172
173
set autocommit=1;
620 by Brian Aker
Remove dead rand structures
174
select @@autocommit;
1 by brian
clean slate
175
set bulk_insert_buffer_size=100;
176
set join_buffer_size=100;
177
set last_insert_id=1;
178
set max_allowed_packet=100;
179
set global max_connect_errors=100;
180
set max_heap_table_size=100;
181
set max_join_size=100;
182
set max_sort_length=100;
183
set global max_write_lock_count=100;
789 by Brian Aker
MyISAM fix.
184
set global myisam_sort_buffer_size=100;
971.7.11 by Eric Day
Fixed header file guards and fixed test cases.
185
set global drizzle_protocol_buffer_length=100;
1 by brian
clean slate
186
set read_buffer_size=100;
187
set read_rnd_buffer_size=100;
188
set global server_id=100;
189
set sort_buffer_size=100;
190
set sql_big_selects=1;
191
set sql_buffer_result=1;
192
set sql_select_limit=1;
193
# reset it, so later tests don't get confused
194
set sql_select_limit=default;
195
set sql_warnings=1;
196
set global table_open_cache=100;
197
set storage_engine=myisam;
198
set timestamp=1, timestamp=default;
199
set tmp_table_size=100;
200
set tx_isolation="READ-COMMITTED";
201
202
#
203
# key buffer
204
#
205
1063.9.46 by Stewart Smith
variables.test for MyISAM as temp only.
206
create temporary table t1 (a int not null auto_increment, primary key(a));
207
create temporary table t2 (a int not null auto_increment, primary key(a));
1 by brian
clean slate
208
insert into t1 values(null),(null),(null);
209
insert into t2 values(null),(null),(null);
1251.2.2 by Jay Pipes
Pulls MyISAM-specific server variables into the MyISAM
210
set global myisam_key_cache_size=100000;
211
select @@myisam_key_cache_size;
1 by brian
clean slate
212
select * from t1 where a=2;
213
select * from t2 where a=3;
214
check table t1,t2;
215
select max(a) +1, max(a) +2 into @xx,@yy from t1;
216
drop table t1,t2;
217
218
#
219
# error conditions
220
#
221
222
--error 1193
223
select @@xxxxxxxxxx;
224
select 1;
225
226
--error 1238
1251.2.2 by Jay Pipes
Pulls MyISAM-specific server variables into the MyISAM
227
select @@session.myisam_key_cache_size;
1 by brian
clean slate
228
971.3.12 by Eric Day
Started abstracting Protocol, removed init_connect, init_file.
229
# init_connect was removed
230
#--error 1229
231
#set init_connect = NULL;
232
#set global init_connect = NULL;
1 by brian
clean slate
233
234
# Bug#3754 SET GLOBAL myisam_max_sort_file_size doesn't work as
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
235
# expected: check that there is no overflow when 64-bit
1 by brian
clean slate
236
# variables are set
237
238
set global myisam_max_sort_file_size=4294967296;
239
--replace_result 4294967296 MAX_FILE_SIZE 2146435072 MAX_FILE_SIZE
240
show global variables like 'myisam_max_sort_file_size';
241
--replace_result 4294967296 MAX_FILE_SIZE 2146435072 MAX_FILE_SIZE
242
select * from information_schema.global_variables where variable_name like 'myisam_max_sort_file_size';
243
set global myisam_max_sort_file_size=default;
244
750 by Brian Aker
Bug #311084
245
## Bug #311084
246
## swap
247
##
248
#select @@global.myisam_max_sort_file_size,@@local.max_join_size;
249
#set @svc=@@global.myisam_max_sort_file_size, @svj=@@local.max_join_size;
250
#select @@global.myisam_max_sort_file_size,@@local.max_join_size;
251
#set @@global.myisam_max_sort_file_size=111,@@local.max_join_size=222;
252
#select @@global.myisam_max_sort_file_size,@@local.max_join_size;
253
#set @@global.myisam_max_sort_file_size=@@local.max_join_size,@@local.max_join_size=@@global.myisam_max_sort_file_size;
254
#select @@global.myisam_max_sort_file_size,@@local.max_join_size;
255
#set @@global.myisam_max_sort_file_size=@svc, @@local.max_join_size=@svj;
256
#select @@global.myisam_max_sort_file_size,@@local.max_join_size;
257
#set @a=1, @b=2;
258
#set @a=@b, @b=@a;
259
#select @a, @b;
1 by brian
clean slate
260
261
#
262
# Bug#2586:Disallow global/session/local as structured var. instance names
263
#
1106.4.2 by Brian Aker
Remove multi key cache
264
--error 1193
1251.2.2 by Jay Pipes
Pulls MyISAM-specific server variables into the MyISAM
265
set @@global.global.myisam_key_cache_size= 1;
1106.4.2 by Brian Aker
Remove multi key cache
266
--error 1193
1251.2.2 by Jay Pipes
Pulls MyISAM-specific server variables into the MyISAM
267
set GLOBAL global.myisam_key_cache_size= 1;
268
--error 1064
269
SELECT @@global.global.myisam_key_cache_size;
270
--error 1064
271
SELECT @@global.session.myisam_key_cache_size;
272
--error 1064
273
SELECT @@global.local.myisam_key_cache_size;
1 by brian
clean slate
274
275
#
276
# BUG#4788 show create table provides incorrect statement
277
#
278
# What default width have numeric types?
1063.9.46 by Stewart Smith
variables.test for MyISAM as temp only.
279
create temporary table t1 (
396 by Brian Aker
Cleanup tiny and small int.
280
  c1 int,
281
  c2 int,
620 by Brian Aker
Remove dead rand structures
282
  c3 int,
1 by brian
clean slate
283
  c4 int,
284
  c5 bigint);
285
show create table t1;
286
drop table t1;
287
#
288
# What types and widths have variables?
289
set @arg00= 8, @arg01= 8.8, @arg02= 'a string', @arg03= 0.2e0;
1063.9.46 by Stewart Smith
variables.test for MyISAM as temp only.
290
create temporary table t1 as select @arg00 as c1, @arg01 as c2, @arg02 as c3, @arg03 as c4;
1 by brian
clean slate
291
show create table t1;
292
drop table t1;
293
294
#
295
# Bug #6958: negative arguments to integer options wrap around
296
#
297
298
SET GLOBAL table_open_cache=-1;
299
SHOW VARIABLES LIKE 'table_open_cache';
971.2.1 by Eric Day
Fix for bug #311025. This was due to code that was removed during ulong cleanup (r576).
300
SELECT * FROM INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME LIKE 'table_open_cache';
1 by brian
clean slate
301
SET GLOBAL table_open_cache=DEFAULT;
302
303
#
304
# Tests for lc_time_names
305
# Note, when adding new locales, please fix ID accordingly:
306
# - to test the last ID (currently 108)
307
# - and the next after the last (currently 109)
308
#
309
--echo *** Various tests with LC_TIME_NAMES
310
--echo *** LC_TIME_NAMES: testing case insensitivity
311
set @@lc_time_names='ru_ru';
312
select @@lc_time_names;
313
--echo *** LC_TIME_NAMES: testing with a user variable
314
set @lc='JA_JP';
315
set @@lc_time_names=@lc;
316
select @@lc_time_names;
317
--echo *** LC_TIME_NAMES: testing with string expressions
318
set lc_time_names=concat('de','_','DE');
319
select @@lc_time_names;
320
--error 1105
321
set lc_time_names=concat('de','+','DE');
322
select @@lc_time_names;
323
--echo LC_TIME_NAMES: testing with numeric expressions
324
set @@lc_time_names=1+2;
325
select @@lc_time_names;
326
--error 1232
327
set @@lc_time_names=1/0;
328
select @@lc_time_names;
329
set lc_time_names=en_US;
330
--echo LC_TIME_NAMES: testing NULL and a negative number:
331
--error 1231
332
set lc_time_names=NULL;
333
--error 1105
334
set lc_time_names=-1;
335
select @@lc_time_names;
336
--echo LC_TIME_NAMES: testing locale with the last ID:
337
set lc_time_names=108;
338
select @@lc_time_names;
339
--echo LC_TIME_NAMES: testing a number beyond the valid ID range:
340
--error 1105
341
set lc_time_names=109;
342
select @@lc_time_names;
343
--echo LC_TIME_NAMES: testing that 0 is en_US:
344
set lc_time_names=0;
345
select @@lc_time_names;
346
347
#
348
# Bug #22648 LC_TIME_NAMES: Setting GLOBAL has no effect
349
#
350
select @@global.lc_time_names, @@lc_time_names;
351
set @@global.lc_time_names=fr_FR;
352
select @@global.lc_time_names, @@lc_time_names;
353
--echo New connection
354
connect (con1,localhost,root,,);
355
connection con1;
356
select @@global.lc_time_names, @@lc_time_names;
357
set @@lc_time_names=ru_RU;
358
select @@global.lc_time_names, @@lc_time_names;
359
disconnect con1;
360
connection default;
361
--echo Returnung to default connection
362
select @@global.lc_time_names, @@lc_time_names;
363
set lc_time_names=default;
364
select @@global.lc_time_names, @@lc_time_names;
365
set @@global.lc_time_names=default;
366
select @@global.lc_time_names, @@lc_time_names;
367
set @@lc_time_names=default;
368
select @@global.lc_time_names, @@lc_time_names;
369
370
371
#
372
# Bug #13334: query_prealloc_size default less than minimum
373
#
374
set @test = @@query_prealloc_size;
375
set @@query_prealloc_size = @test;
376
select @@query_prealloc_size = @test;
377
378
--echo End of 4.1 tests
379
380
#
381
# Bug#6282 Packet error with SELECT INTO
382
# 
383
1063.9.46 by Stewart Smith
variables.test for MyISAM as temp only.
384
create temporary table t1 (a int);
1 by brian
clean slate
385
select a into @x from t1;
386
show warnings;
387
drop table t1;
388
389
#
390
# Bug #10339: read only variables.
391
#
392
393
--error 1238
394
set @@warning_count=1;
395
--error 1238
396
set @@global.error_count=1;
397
398
#
399
# Bug #10351: Setting ulong variable to > MAX_ULONG fails on 32-bit platform
400
#
1194 by Brian Aker
Removed test for ARCH (it only looked at Intel style systems). Left in SELECT for it.
401
--disable_query_log
402
select VARIABLE_VALUE from information_schema.GLOBAL_VARIABLES where VARIABLE_NAME like "VERSION_COMPILE_MACHINE" into @arch;
403
--enable_query_log
1197 by Brian Aker
Remove test for 32bit max on heap tables.
404
# We technically do not care about 32bit hardware. -Brian
405
#set @@max_heap_table_size= 4294967296;
406
#select @@max_heap_table_size > 0;
407
#set global max_heap_table_size= 4294967296;
408
#select @@max_heap_table_size > 0;
409
#set @@max_heap_table_size= 4294967296;
410
#select @@max_heap_table_size > 0;
1124.2.12 by Diego Medina
finally fixed the 64-bit vs 32-bit test case
411
--enable_warnings
1 by brian
clean slate
412
#
413
# Bug #11775 Variable character_set_system does not exist (sometimes)
414
#
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
415
--error 1193
1 by brian
clean slate
416
select @@character_set_system;
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
417
--error 1193
418
set global character_set_system = utf8;
1 by brian
clean slate
419
--error 1238
420
set @@global.version_compile_os='234';
421
422
#
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
423
# Check character_set_filesystem variable invalid for Drizzle
1 by brian
clean slate
424
#
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
425
--error 1193
426
set @@global.character_set_filesystem=utf8;
427
--error 1193
428
set character_set_filesystem=utf8;
1 by brian
clean slate
429
430
#
431
# Bug #17849: Show sql_big_selects in SHOW VARIABLES
432
#
433
set @old_sql_big_selects = @@sql_big_selects;
434
set @@sql_big_selects = 1;
435
show variables like 'sql_big_selects';
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
436
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
437
#select * from information_schema.session_variables where variable_name like 'sql_big_selects';
1 by brian
clean slate
438
set @@sql_big_selects = @old_sql_big_selects;
439
440
#
441
# Bug #16195: SHOW VARIABLES doesn't report correctly sql_warnings and
442
# sql_notes values
443
# 
444
set @@sql_notes = 0, @@sql_warnings = 0;
445
show variables like 'sql_notes';
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
446
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
447
#select * from information_schema.session_variables where variable_name like 'sql_notes';
1 by brian
clean slate
448
show variables like 'sql_warnings';
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
449
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
450
#select * from information_schema.session_variables where variable_name like 'sql_warnings';
1 by brian
clean slate
451
set @@sql_notes = 1, @@sql_warnings = 1;
452
show variables like 'sql_notes';
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
453
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
454
#select * from information_schema.session_variables where variable_name like 'sql_notes';
1 by brian
clean slate
455
show variables like 'sql_warnings';
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
456
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
457
#select * from information_schema.session_variables where variable_name like 'sql_warnings';
1 by brian
clean slate
458
459
#
460
# Bug #15684: system variables cannot be SELECTed (e.g. @@version_comment)
461
#
462
# Don't actually output, since it depends on the system
463
--replace_column 1 # 2 # 3 # 4 #
464
select @@version, @@version_comment, @@version_compile_machine,
465
       @@version_compile_os;
466
467
#
468
# Bug #1039: make tmpdir and datadir available as @@variables (also included
469
# basedir)
470
#
471
# Don't actually output, since it depends on the system
472
--replace_column 1 # 2 # 3 #
473
select @@basedir, @@datadir, @@tmpdir;
474
--replace_column 2 #
475
show variables like 'basedir';
476
--replace_column 2 #
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
477
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
478
#select * from information_schema.session_variables where variable_name like 'basedir';
1 by brian
clean slate
479
--replace_column 2 #
480
show variables like 'datadir';
481
--replace_column 2 #
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
482
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
483
#select * from information_schema.session_variables where variable_name like 'datadir';
1 by brian
clean slate
484
--replace_column 2 #
485
show variables like 'tmpdir';
486
--replace_column 2 #
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
487
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
488
#select * from information_schema.session_variables where variable_name like 'tmpdir';
1 by brian
clean slate
489
490
#
491
# Bug #19606: make ssl settings available via SHOW VARIABLES and @@variables
492
# 
493
# Don't actually output, since it depends on the system
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
494
#--replace_column 1 # 2 # 3 # 4 # 5 #
495
# Not supported in Drizzle
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
496
#select @@ssl_ca, @@ssl_capath, @@ssl_cert, @@ssl_cipher, @@ssl_key;
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
497
#--replace_column 2 #
498
#show variables like 'ssl%';
499
#--replace_column 2 #
500
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
501
#select * from information_schema.session_variables where variable_name like 'ssl%' order by 1;
1 by brian
clean slate
502
503
#
504
# Bug #19616: make log_queries_not_using_indexes available in SHOW VARIABLES
505
# and as @@log_queries_not_using_indexes
506
#
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
507
# Not valid in Drizzle
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
508
#select @@log_queries_not_using_indexes;
509
#show variables like 'log_queries_not_using_indexes';
642.1.53 by Lee
enable subselect_not, subselect_no_mat and variables tests, some other misc clean up on other tests
510
# Bug 311025 Segmentation fault when accessing INFORMATION_SCHEMA
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
511
#select * from information_schema.session_variables where variable_name like 'log_queries_not_using_indexes';
1 by brian
clean slate
512
513
#
514
# Bug#20908: Crash if select @@""
515
#
516
--error ER_PARSE_ERROR
517
select @@"";
518
--error ER_PARSE_ERROR
519
select @@&;
520
--error ER_PARSE_ERROR
521
select @@@;
522
523
#
524
# Bug#20166 mysql-test-run.pl does not test system privilege tables creation
525
#
526
# Don't actually output, since it depends on the system
527
--replace_column 1 #
528
select @@hostname;
529
--error 1238
530
set @@hostname= "anothername";
531
--replace_column 2 #
532
show variables like 'hostname';
533
534
--echo End of 5.0 tests
535
536
# This is at the very after the versioned tests, since it involves doing
537
# cleanup
538
#
539
# Bug #19263: variables.test doesn't clean up after itself (II/II --
540
# restore)
541
#
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
542
--error 1193
1 by brian
clean slate
543
set global flush_time                =@my_flush_time;
1251.2.2 by Jay Pipes
Pulls MyISAM-specific server variables into the MyISAM
544
set global myisam_key_cache_size           =@my_myisam_key_cache_size;
1 by brian
clean slate
545
set global max_connect_errors        =@my_max_connect_errors;
546
set global max_heap_table_size       =@my_max_heap_table_size;
547
set global max_join_size             =@my_max_join_size;
548
# No default
549
set global max_write_lock_count      =default;
790 by Brian Aker
More myisam plugin conversion.
550
--error 1232
1 by brian
clean slate
551
set global myisam_data_pointer_size  =@my_myisam_data_pointer_size;
971.7.11 by Eric Day
Fixed header file guards and fixed test cases.
552
set global drizzle_protocol_buffer_length= @my_drizzle_protocol_buffer_length;
1 by brian
clean slate
553
set global server_id                 =@my_server_id;
554
set global storage_engine            =@my_storage_engine;
642.1.51 by Lee
enable user_var, user_var-binlog and symlink tests
555
--error 1193
1 by brian
clean slate
556
set global thread_cache_size         =@my_thread_cache_size;
1119.4.7 by Stewart Smith
make variables test not leave state of server in a modified state. i.e. fully
557
set global myisam_sort_buffer_size   =@my_myisam_sort_buffer_size;
1 by brian
clean slate
558
559
#
560
# Bug#28580 Repeatation of status variables
561
#
562
--replace_column 2 #
1055.1.2 by Padraig O'Sullivan
Updated test case based on bug fix.
563
show global variables where variable_name='table_definition_cache' or Variable_name='table_lock_wait_timeout';