| 1 |
# set global |
| 2 |
--source include/have_maria.inc |
| 3 |
|
| 4 |
SET @start_global_value = @@global.aria_recover_options; |
| 5 |
set @@global.aria_recover_options=default; |
| 6 |
|
| 7 |
# |
| 8 |
# exists as global only |
| 9 |
# |
| 10 |
select @@global.aria_recover_options; |
| 11 |
--error ER_INCORRECT_GLOBAL_LOCAL_VAR |
| 12 |
select @@session.aria_recover_options; |
| 13 |
show global variables like 'aria_recover_options'; |
| 14 |
show session variables like 'aria_recover_options'; |
| 15 |
select * from information_schema.global_variables where variable_name='aria_recover_options'; |
| 16 |
select * from information_schema.session_variables where variable_name='aria_recover_options'; |
| 17 |
|
| 18 |
# |
| 19 |
# show that it's writable |
| 20 |
# |
| 21 |
set global aria_recover_options=1; |
| 22 |
select @@global.aria_recover_options; |
| 23 |
--error ER_GLOBAL_VARIABLE |
| 24 |
set session aria_recover_options=1; |
| 25 |
|
| 26 |
# |
| 27 |
# valid values |
| 28 |
# |
| 29 |
set global aria_recover_options=normal; |
| 30 |
select @@global.aria_recover_options; |
| 31 |
set global aria_recover_options=backup; |
| 32 |
select @@global.aria_recover_options; |
| 33 |
set global aria_recover_options='force'; |
| 34 |
select @@global.aria_recover_options; |
| 35 |
set global aria_recover_options=off; |
| 36 |
select @@global.aria_recover_options; |
| 37 |
set global aria_recover_options='quick,force'; |
| 38 |
select @@global.aria_recover_options; |
| 39 |
set global aria_recover_options=16; |
| 40 |
select @@global.aria_recover_options; |
| 41 |
|
| 42 |
# |
| 43 |
# incorrect types/values |
| 44 |
# |
| 45 |
--error ER_WRONG_TYPE_FOR_VAR |
| 46 |
set global aria_recover_options=1.1; |
| 47 |
--error ER_WRONG_TYPE_FOR_VAR |
| 48 |
set global aria_recover_options=1e1; |
| 49 |
--error ER_WRONG_VALUE_FOR_VAR |
| 50 |
set global aria_recover_options="foo"; |
| 51 |
--error ER_WRONG_VALUE_FOR_VAR |
| 52 |
set global aria_recover_options=32; |
| 53 |
|
| 54 |
SET @@global.aria_recover_options = @start_global_value; |