| 1 |
|
| 2 |
# |
| 3 |
# 2010-01-25 - Added |
| 4 |
# |
| 5 |
|
| 6 |
|
| 7 |
SET @start_global_value = @@global.innodb_old_blocks_time; |
| 8 |
SELECT @start_global_value; |
| 9 |
|
| 10 |
# |
| 11 |
# exists as global only |
| 12 |
# |
| 13 |
--echo Valid values are zero or above |
| 14 |
select @@global.innodb_old_blocks_time >=0; |
| 15 |
select @@global.innodb_old_blocks_time; |
| 16 |
--error ER_INCORRECT_GLOBAL_LOCAL_VAR |
| 17 |
select @@session.innodb_old_blocks_time; |
| 18 |
show global variables like 'innodb_old_blocks_time'; |
| 19 |
show session variables like 'innodb_old_blocks_time'; |
| 20 |
--disable_warnings |
| 21 |
select * from performance_schema.global_variables where variable_name='innodb_old_blocks_time'; |
| 22 |
select * from performance_schema.session_variables where variable_name='innodb_old_blocks_time'; |
| 23 |
--enable_warnings |
| 24 |
|
| 25 |
# |
| 26 |
# show that it's writable |
| 27 |
# |
| 28 |
set global innodb_old_blocks_time=10; |
| 29 |
select @@global.innodb_old_blocks_time; |
| 30 |
--disable_warnings |
| 31 |
select * from performance_schema.global_variables where variable_name='innodb_old_blocks_time'; |
| 32 |
select * from performance_schema.session_variables where variable_name='innodb_old_blocks_time'; |
| 33 |
--enable_warnings |
| 34 |
--error ER_GLOBAL_VARIABLE |
| 35 |
set session innodb_old_blocks_time=1; |
| 36 |
|
| 37 |
# |
| 38 |
# incorrect types |
| 39 |
# |
| 40 |
--error ER_WRONG_TYPE_FOR_VAR |
| 41 |
set global innodb_old_blocks_time=1.1; |
| 42 |
--error ER_WRONG_TYPE_FOR_VAR |
| 43 |
set global innodb_old_blocks_time=1e1; |
| 44 |
--error ER_WRONG_TYPE_FOR_VAR |
| 45 |
set global innodb_old_blocks_time="foo"; |
| 46 |
|
| 47 |
set global innodb_old_blocks_time=-7; |
| 48 |
select @@global.innodb_old_blocks_time; |
| 49 |
--disable_warnings |
| 50 |
select * from performance_schema.global_variables where variable_name='innodb_old_blocks_time'; |
| 51 |
--enable_warnings |
| 52 |
|
| 53 |
# |
| 54 |
# cleanup |
| 55 |
# |
| 56 |
SET @@global.innodb_old_blocks_time = @start_global_value; |
| 57 |
SELECT @@global.innodb_old_blocks_time; |