1SET @start_global_value = @@global.innodb_large_prefix;
2SELECT @start_global_value;
3@start_global_value
40
5Valid values are 'ON' and 'OFF'
6select @@global.innodb_large_prefix in (0, 1);
7@@global.innodb_large_prefix in (0, 1)
81
9select @@global.innodb_large_prefix;
10@@global.innodb_large_prefix
110
12select @@session.innodb_large_prefix;
13ERROR HY000: Variable 'innodb_large_prefix' is a GLOBAL variable
14show global variables like 'innodb_large_prefix';
15Variable_name	Value
16innodb_large_prefix	OFF
17show session variables like 'innodb_large_prefix';
18Variable_name	Value
19innodb_large_prefix	OFF
20select * from information_schema.global_variables where variable_name='innodb_large_prefix';
21VARIABLE_NAME	VARIABLE_VALUE
22INNODB_LARGE_PREFIX	OFF
23select * from information_schema.session_variables where variable_name='innodb_large_prefix';
24VARIABLE_NAME	VARIABLE_VALUE
25INNODB_LARGE_PREFIX	OFF
26set global innodb_large_prefix='OFF';
27select @@global.innodb_large_prefix;
28@@global.innodb_large_prefix
290
30select * from information_schema.global_variables where variable_name='innodb_large_prefix';
31VARIABLE_NAME	VARIABLE_VALUE
32INNODB_LARGE_PREFIX	OFF
33select * from information_schema.session_variables where variable_name='innodb_large_prefix';
34VARIABLE_NAME	VARIABLE_VALUE
35INNODB_LARGE_PREFIX	OFF
36set @@global.innodb_large_prefix=1;
37select @@global.innodb_large_prefix;
38@@global.innodb_large_prefix
391
40select * from information_schema.global_variables where variable_name='innodb_large_prefix';
41VARIABLE_NAME	VARIABLE_VALUE
42INNODB_LARGE_PREFIX	ON
43select * from information_schema.session_variables where variable_name='innodb_large_prefix';
44VARIABLE_NAME	VARIABLE_VALUE
45INNODB_LARGE_PREFIX	ON
46set global innodb_large_prefix=0;
47select @@global.innodb_large_prefix;
48@@global.innodb_large_prefix
490
50select * from information_schema.global_variables where variable_name='innodb_large_prefix';
51VARIABLE_NAME	VARIABLE_VALUE
52INNODB_LARGE_PREFIX	OFF
53select * from information_schema.session_variables where variable_name='innodb_large_prefix';
54VARIABLE_NAME	VARIABLE_VALUE
55INNODB_LARGE_PREFIX	OFF
56set @@global.innodb_large_prefix='ON';
57select @@global.innodb_large_prefix;
58@@global.innodb_large_prefix
591
60select * from information_schema.global_variables where variable_name='innodb_large_prefix';
61VARIABLE_NAME	VARIABLE_VALUE
62INNODB_LARGE_PREFIX	ON
63select * from information_schema.session_variables where variable_name='innodb_large_prefix';
64VARIABLE_NAME	VARIABLE_VALUE
65INNODB_LARGE_PREFIX	ON
66set session innodb_large_prefix='OFF';
67ERROR HY000: Variable 'innodb_large_prefix' is a GLOBAL variable and should be set with SET GLOBAL
68set @@session.innodb_large_prefix='ON';
69ERROR HY000: Variable 'innodb_large_prefix' is a GLOBAL variable and should be set with SET GLOBAL
70set global innodb_large_prefix=1.1;
71ERROR 42000: Incorrect argument type to variable 'innodb_large_prefix'
72set global innodb_large_prefix=1e1;
73ERROR 42000: Incorrect argument type to variable 'innodb_large_prefix'
74set global innodb_large_prefix=2;
75ERROR 42000: Variable 'innodb_large_prefix' can't be set to the value of '2'
76NOTE: The following should fail with ER_WRONG_VALUE_FOR_VAR (BUG#50643)
77set global innodb_large_prefix=-3;
78select @@global.innodb_large_prefix;
79@@global.innodb_large_prefix
801
81select * from information_schema.global_variables where variable_name='innodb_large_prefix';
82VARIABLE_NAME	VARIABLE_VALUE
83INNODB_LARGE_PREFIX	ON
84select * from information_schema.session_variables where variable_name='innodb_large_prefix';
85VARIABLE_NAME	VARIABLE_VALUE
86INNODB_LARGE_PREFIX	ON
87set global innodb_large_prefix='AUTO';
88ERROR 42000: Variable 'innodb_large_prefix' can't be set to the value of 'AUTO'
89SET @@global.innodb_large_prefix = @start_global_value;
90SELECT @@global.innodb_large_prefix;
91@@global.innodb_large_prefix
920
93