Debian Codegraph @

mysql-test/suite/sys_vars/t/sync_source_info_basic.test

raw
1
2 SET @start_global_value = @@global.sync_source_info;
3 SELECT @start_global_value;
4
5 #
6 # exists as global only
7 #
8 select @@global.sync_source_info;
9 --error ER_INCORRECT_GLOBAL_LOCAL_VAR
10 select @@session.sync_source_info;
11 show global variables like 'sync_source_info';
12 show session variables like 'sync_source_info';
13 --disable_warnings
14 select * from performance_schema.global_variables where variable_name='sync_source_info';
15 select * from performance_schema.session_variables where variable_name='sync_source_info';
16 --enable_warnings
17
18 #
19 # show that it's writable
20 #
21 set global sync_source_info=1;
22 select @@global.sync_source_info;
23 --error ER_GLOBAL_VARIABLE
24 set session sync_source_info=1;
25
26 #
27 # incorrect types
28 #
29 --error ER_WRONG_TYPE_FOR_VAR
30 set global sync_source_info=1.1;
31 --error ER_WRONG_TYPE_FOR_VAR
32 set global sync_source_info=1e1;
33 --error ER_WRONG_TYPE_FOR_VAR
34 set global sync_source_info="foo";
35
36 #
37 # min/max values
38 #
39 set global sync_source_info=0;
40 select @@global.sync_source_info;
41 set global sync_source_info=cast(-1 as unsigned int);
42 select @@global.sync_source_info;
43
44 SET @@global.sync_source_info = @start_global_value;
45 SELECT @@global.sync_source_info;