mirror of
https://github.com/MariaDB/server.git
synced 2025-01-30 18:41:56 +01:00
ffbb2bbc09
This is covered in mysql-test/t/variables.test. There is no sense to test this for every individual variables. This is to reduce the coming soon patch for ROW-type routine variables, which will change the error from ER_PARSE_ERROR to a new error "unknown structured variable".
95 lines
3.8 KiB
Text
95 lines
3.8 KiB
Text
SET @start_value = @@global.event_scheduler;
|
|
SELECT @start_value;
|
|
@start_value
|
|
OFF
|
|
'#---------------------FN_DYNVARS_004_01-------------------------#'
|
|
SET @@global.event_scheduler = DEFAULT;
|
|
SELECT @@global.event_scheduler;
|
|
@@global.event_scheduler
|
|
OFF
|
|
'#--------------------FN_DYNVARS_004_02------------------------#'
|
|
SET @@global.event_scheduler = ON;
|
|
SELECT @@global.event_scheduler;
|
|
@@global.event_scheduler
|
|
ON
|
|
SET @@global.event_scheduler = OFF;
|
|
SELECT @@global.event_scheduler;
|
|
@@global.event_scheduler
|
|
OFF
|
|
SET @@global.event_scheduler = DISABLED;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of 'DISABLED'
|
|
SELECT @@global.event_scheduler;
|
|
@@global.event_scheduler
|
|
OFF
|
|
'#--------------------FN_DYNVARS_004_03-------------------------#'
|
|
SET @@global.event_scheduler = 2;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of '2'
|
|
SET @@global.event_scheduler = -1;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of '-1'
|
|
SET @@global.event_scheduler = TRUEF;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of 'TRUEF'
|
|
SET @@global.event_scheduler = TRUE_F;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of 'TRUE_F'
|
|
SET @@global.event_scheduler = FALSE0;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of 'FALSE0'
|
|
SET @@global.event_scheduler = OON;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of 'OON'
|
|
SET @@global.event_scheduler = ONN;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of 'ONN'
|
|
SET @@global.event_scheduler = OOFF;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of 'OOFF'
|
|
SET @@global.event_scheduler = 0FF;
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of '0FF'
|
|
SET @@global.event_scheduler = ' ';
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of ' '
|
|
SET @@global.event_scheduler = " ";
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of ' '
|
|
SET @@global.event_scheduler = '';
|
|
ERROR 42000: Variable 'event_scheduler' can't be set to the value of ''
|
|
'#-------------------FN_DYNVARS_004_04----------------------------#'
|
|
SET @@session.event_scheduler = OFF;
|
|
ERROR HY000: Variable 'event_scheduler' is a GLOBAL variable and should be set with SET GLOBAL
|
|
SELECT @@session.event_scheduler;
|
|
ERROR HY000: Variable 'event_scheduler' is a GLOBAL variable
|
|
'#----------------------FN_DYNVARS_004_05------------------------#'
|
|
SELECT @@global.event_scheduler = VARIABLE_VALUE
|
|
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
|
|
WHERE VARIABLE_NAME='event_scheduler';
|
|
@@global.event_scheduler = VARIABLE_VALUE
|
|
1
|
|
'#---------------------FN_DYNVARS_004_06----------------------#'
|
|
SET @@global.event_scheduler = 0;
|
|
SELECT @@global.event_scheduler;
|
|
@@global.event_scheduler
|
|
OFF
|
|
SET @@global.event_scheduler = 1;
|
|
SELECT @@global.event_scheduler;
|
|
@@global.event_scheduler
|
|
ON
|
|
'#---------------------FN_DYNVARS_004_07----------------------#'
|
|
SET @@global.event_scheduler = TRUE;
|
|
SELECT @@global.event_scheduler;
|
|
@@global.event_scheduler
|
|
ON
|
|
SET @@global.event_scheduler = FALSE;
|
|
SELECT @@global.event_scheduler;
|
|
@@global.event_scheduler
|
|
OFF
|
|
'#---------------------FN_DYNVARS_004_08----------------------#'
|
|
SET @@global.event_scheduler = ON;
|
|
SELECT @@event_scheduler = @@global.event_scheduler;
|
|
@@event_scheduler = @@global.event_scheduler
|
|
1
|
|
'#---------------------FN_DYNVARS_004_09----------------------#'
|
|
SET event_scheduler = ON;
|
|
ERROR HY000: Variable 'event_scheduler' is a GLOBAL variable and should be set with SET GLOBAL
|
|
SELECT local.event_scheduler;
|
|
ERROR 42S02: Unknown table 'local' in field list
|
|
SELECT global.event_scheduler;
|
|
ERROR 42S02: Unknown table 'global' in field list
|
|
SELECT event_scheduler = @@session.event_scheduler;
|
|
ERROR 42S22: Unknown column 'event_scheduler' in 'field list'
|
|
SET @@global.event_scheduler = @start_value;
|
|
SELECT @@global.event_scheduler;
|
|
@@global.event_scheduler
|
|
OFF
|