Debian Codegraph @

mysql-test/suite/wsrep/r/wsrep_on_basic.result

raw
1 #
2 # wsrep_on
3 #
4 # save the initial values
5 SET @wsrep_on_global_saved = @@global.wsrep_on;
6 SET @wsrep_on_session_saved = @@session.wsrep_on;
7 # default
8 SELECT @@global.wsrep_on;
9 @@global.wsrep_on
10 1
11 SELECT @@session.wsrep_on;
12 @@session.wsrep_on
13 1
14
15 # scope and valid values
16 SET @@global.wsrep_on=OFF;
17 SELECT @@global.wsrep_on;
18 @@global.wsrep_on
19 0
20 SET @@global.wsrep_on=ON;
21 SELECT @@global.wsrep_on;
22 @@global.wsrep_on
23 1
24 SET @@session.wsrep_on=OFF;
25 SELECT @@session.wsrep_on;
26 @@session.wsrep_on
27 0
28 SET @@session.wsrep_on=ON;
29 SELECT @@session.wsrep_on;
30 @@session.wsrep_on
31 1
32 SET @@session.wsrep_on=default;
33 SELECT @@session.wsrep_on;
34 @@session.wsrep_on
35 1
36
37 # invalid values
38 SET @@global.wsrep_on=NULL;
39 ERROR 42000: Variable 'wsrep_on' can't be set to the value of 'NULL'
40 SET @@global.wsrep_on='junk';
41 ERROR 42000: Variable 'wsrep_on' can't be set to the value of 'junk'
42 SET @@session.wsrep_on=NULL;
43 ERROR 42000: Variable 'wsrep_on' can't be set to the value of 'NULL'
44 SET @@session.wsrep_on='junk';
45 ERROR 42000: Variable 'wsrep_on' can't be set to the value of 'junk'
46
47 # restore the initial values
48 SET @@global.wsrep_on = @wsrep_on_global_saved;
49 SET @@session.wsrep_on = @wsrep_on_session_saved;
50 # End of test