summaryrefslogtreecommitdiff
path: root/mysql-test/suite/sys_vars/t/skip_replication_basic.test
blob: da1b6c5f2e17c42f20934819e0ca527c4de41f97 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# exists as a session only
 
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
select @@global.skip_replication;

# Check the variable has a valid numeric value (assumed to be less then 10000)
select @@session.skip_replication between 1 and 10000;

--echo should be empty
show global variables like 'skip_replication';
show session variables like 'skip_replication';

# Global I_S variable is empty
--echo should be empty
select * from information_schema.global_variables where variable_name='skip_replication';

# Check that I_S value is same as variable
select @@session.skip_replication = variable_value from information_schema.session_variables where variable_name='skip_replication';

#
# show that it's writable
#
set session skip_replication=0;
select @@session.skip_replication;
set session skip_replication=1;
select @@session.skip_replication;
select * from information_schema.global_variables where variable_name='skip_replication';
select variable_value from information_schema.session_variables where variable_name='skip_replication';
--error ER_LOCAL_VARIABLE
set global skip_replication=1;