Debian Codegraph @

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

raw
1
2
3 ################## mysql-test\t\innodb_log_file_size_basic.test ###############
4 # #
5 # Variable Name: innodb_log_file_size #
6 # Scope: Global #
7 # Access Type: Static #
8 # Data Type: numeric #
9 # #
10 # #
11 # Creation Date: 2008-02-07 #
12 # Author : Sharique Abdullah #
13 # #
14 # #
15 # Description:Test Cases of Dynamic System Variable innodb_log_file_size #
16 # that checks the behavior of this variable in the following ways #
17 # * Value Check #
18 # * Scope Check #
19 # #
20 # Reference: http://dev.mysql.com/doc/refman/5.1/en/ #
21 # server-system-variables.html #
22 # #
23 ###############################################################################
24
25
26 --echo '#---------------------BS_STVARS_035_01----------------------#'
27 ####################################################################
28 # Displaying default value #
29 ####################################################################
30 SELECT COUNT(@@GLOBAL.innodb_log_file_size);
31 --echo 1 Expected
32
33 SELECT @@GLOBAL.innodb_log_file_size;
34
35
36
37 --echo '#---------------------BS_STVARS_035_02----------------------#'
38 ####################################################################
39 # Check if Value can set #
40 ####################################################################
41
42 --error ER_INCORRECT_GLOBAL_LOCAL_VAR
43 SET @@local.innodb_log_file_size=1;
44 --echo Expected error 'Read only variable'
45
46 --error ER_INCORRECT_GLOBAL_LOCAL_VAR
47 SET @@session.innodb_log_file_size=1;
48 --echo Expected error 'Read only variable'
49
50 --error ER_INCORRECT_GLOBAL_LOCAL_VAR
51 SET @@GLOBAL.innodb_log_file_size=1;
52 --echo Expected error 'Read only variable'
53
54 --error ER_INCORRECT_GLOBAL_LOCAL_VAR
55 SET @@GLOBAL.innodb_log_file_size=DEFAULT;
56 --echo Expected error 'Read only variable'
57
58 SELECT COUNT(@@GLOBAL.innodb_log_file_size);
59 --echo 1 Expected
60
61
62
63 --echo '#---------------------BS_STVARS_035_03----------------------#'
64 #################################################################
65 # Check if the value in GLOBAL Table matches value in variable #
66 #################################################################
67
68 --disable_warnings
69 SELECT @@GLOBAL.innodb_log_file_size = VARIABLE_VALUE
70 FROM performance_schema.global_variables
71 WHERE VARIABLE_NAME='innodb_log_file_size';
72 --enable_warnings
73 --echo 1 Expected
74
75 SELECT COUNT(@@GLOBAL.innodb_log_file_size);
76 --echo 1 Expected
77
78 --disable_warnings
79 SELECT COUNT(VARIABLE_VALUE)
80 FROM performance_schema.global_variables
81 WHERE VARIABLE_NAME='innodb_log_file_size';
82 --enable_warnings
83 --echo 1 Expected
84
85
86
87 --echo '#---------------------BS_STVARS_035_04----------------------#'
88 ################################################################################
89 # Check if accessing variable with and without GLOBAL point to same variable #
90 ################################################################################
91 SELECT @@innodb_log_file_size = @@GLOBAL.innodb_log_file_size;
92 --echo 1 Expected
93
94
95
96 --echo '#---------------------BS_STVARS_035_05----------------------#'
97 ################################################################################
98 # Check if innodb_log_file_size can be accessed with and without @@ sign #
99 ################################################################################
100
101 SELECT COUNT(@@innodb_log_file_size);
102 --echo 1 Expected
103
104 --Error ER_INCORRECT_GLOBAL_LOCAL_VAR
105 SELECT COUNT(@@local.innodb_log_file_size);
106 --echo Expected error 'Variable is a GLOBAL variable'
107
108 --Error ER_INCORRECT_GLOBAL_LOCAL_VAR
109 SELECT COUNT(@@SESSION.innodb_log_file_size);
110 --echo Expected error 'Variable is a GLOBAL variable'
111
112 SELECT COUNT(@@GLOBAL.innodb_log_file_size);
113 --echo 1 Expected
114
115 --Error ER_BAD_FIELD_ERROR
116 SELECT innodb_log_file_size;
117 --echo Expected error 'Unknown column'
118