Commit d1fb6bbc authored by Tatiana A. Nurnberg's avatar Tatiana A. Nurnberg

Bug#40657: assertion with out of range variables and traditional sql_mode

In STRICT mode, out-of-bounds values caused an error message
to be queued (rather than just a warning), without any further
error-like processing happening. (The error is queued during
update, at which time it's too late. For it to be processed
properly, it would need to be queued during check-stage.)
The assertion rightfully complains that we're trying to send
an OK while having an error queued.

Changeset breaks a lot of tests out into check-stage. This also
allows us to send more correct warnings/error messages.

mysql-test/r/auto_increment_increment_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/auto_increment_increment_func.result:
  update test results reflecting more correct warnings
mysql-test/r/auto_increment_offset_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/auto_increment_offset_func.result:
  update test results reflecting more correct warnings
mysql-test/r/concurrent_insert_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/connect_timeout_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/default_week_format_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/delayed_insert_timeout_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/div_precision_increment_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/expire_logs_days_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/group_concat_max_len_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/interactive_timeout_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_allowed_packet_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_binlog_size_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_connections_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_delayed_threads_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_error_count_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_insert_delayed_threads_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_length_for_sort_data_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_prepared_stmt_count_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_relay_log_size_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_sort_length_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/max_sp_recursion_depth_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/myisam_data_pointer_size_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/net_buffer_length_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/net_read_timeout_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/net_write_timeout_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/optimizer_prune_level_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/optimizer_search_depth_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/preload_buffer_size_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/ps.result:
  update test results reflecting more correct warnings
mysql-test/r/read_buffer_size_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/read_rnd_buffer_size_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/slave_net_timeout_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/slow_launch_time_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/table_definition_cache_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/table_lock_wait_timeout_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/table_open_cache_basic.result:
  update test results reflecting more correct warnings
mysql-test/r/variables.result:
  add test case that throws error (rather than warning)
  in the middle of trying to set a system-variable.
mysql-test/t/variables.test:
  add test case that throws error (rather than warning)
  in the middle of trying to set a system-variable.
sql/set_var.cc:
  Add comments.
  Prevent double-warnings.
  Through warnings for negative values given to unsigned
  system-variables.
  Process errors and warnings at check() stage rather than
  update() stage, since we may only issue warnings at the latter.
parent 622db260
...@@ -61,7 +61,7 @@ SELECT @@global.auto_increment_increment; ...@@ -61,7 +61,7 @@ SELECT @@global.auto_increment_increment;
1 1
SET @@global.auto_increment_increment = -1024; SET @@global.auto_increment_increment = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect auto-increment-increment value: '0' Warning 1292 Truncated incorrect auto_increment_increment value: '-1024'
SELECT @@global.auto_increment_increment; SELECT @@global.auto_increment_increment;
@@global.auto_increment_increment @@global.auto_increment_increment
1 1
...@@ -89,7 +89,7 @@ SELECT @@session.auto_increment_increment; ...@@ -89,7 +89,7 @@ SELECT @@session.auto_increment_increment;
1 1
SET @@session.auto_increment_increment = -2; SET @@session.auto_increment_increment = -2;
Warnings: Warnings:
Warning 1292 Truncated incorrect auto-increment-increment value: '0' Warning 1292 Truncated incorrect auto_increment_increment value: '-2'
SELECT @@session.auto_increment_increment; SELECT @@session.auto_increment_increment;
@@session.auto_increment_increment @@session.auto_increment_increment
1 1
......
...@@ -169,7 +169,7 @@ id name ...@@ -169,7 +169,7 @@ id name
## Verifying behavior of variable with negative value ## ## Verifying behavior of variable with negative value ##
SET @@auto_increment_increment = -10; SET @@auto_increment_increment = -10;
Warnings: Warnings:
Warning 1292 Truncated incorrect auto-increment-increment value: '0' Warning 1292 Truncated incorrect auto_increment_increment value: '-10'
INSERT into t1(name) values('Record_17'); INSERT into t1(name) values('Record_17');
INSERT into t1(name) values('Record_18'); INSERT into t1(name) values('Record_18');
SELECT * from t1; SELECT * from t1;
......
...@@ -61,7 +61,7 @@ SELECT @@global.auto_increment_offset; ...@@ -61,7 +61,7 @@ SELECT @@global.auto_increment_offset;
1 1
SET @@global.auto_increment_offset = -1024; SET @@global.auto_increment_offset = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect auto-increment-offset value: '0' Warning 1292 Truncated incorrect auto_increment_offset value: '-1024'
SELECT @@global.auto_increment_offset; SELECT @@global.auto_increment_offset;
@@global.auto_increment_offset @@global.auto_increment_offset
1 1
...@@ -94,7 +94,7 @@ SELECT @@session.auto_increment_offset; ...@@ -94,7 +94,7 @@ SELECT @@session.auto_increment_offset;
1 1
SET @@session.auto_increment_offset = -2; SET @@session.auto_increment_offset = -2;
Warnings: Warnings:
Warning 1292 Truncated incorrect auto-increment-offset value: '0' Warning 1292 Truncated incorrect auto_increment_offset value: '-2'
SELECT @@session.auto_increment_offset; SELECT @@session.auto_increment_offset;
@@session.auto_increment_offset @@session.auto_increment_offset
1 1
......
...@@ -178,7 +178,7 @@ id name ...@@ -178,7 +178,7 @@ id name
## Assigning -ve value to variable ## ## Assigning -ve value to variable ##
SET @@auto_increment_offset = -10; SET @@auto_increment_offset = -10;
Warnings: Warnings:
Warning 1292 Truncated incorrect auto-increment-offset value: '0' Warning 1292 Truncated incorrect auto_increment_offset value: '-10'
SELECT @@auto_increment_offset = -10; SELECT @@auto_increment_offset = -10;
@@auto_increment_offset = -10 @@auto_increment_offset = -10
0 0
......
...@@ -28,6 +28,8 @@ SELECT @@global.concurrent_insert; ...@@ -28,6 +28,8 @@ SELECT @@global.concurrent_insert;
2 2
'#--------------------FN_DYNVARS_018_04-------------------------#' '#--------------------FN_DYNVARS_018_04-------------------------#'
SET @@global.concurrent_insert = -1; SET @@global.concurrent_insert = -1;
Warnings:
Warning 1292 Truncated incorrect concurrent_insert value: '-1'
Select @@global.concurrent_insert; Select @@global.concurrent_insert;
@@global.concurrent_insert @@global.concurrent_insert
0 0
......
...@@ -35,7 +35,7 @@ SELECT @@global.connect_timeout; ...@@ -35,7 +35,7 @@ SELECT @@global.connect_timeout;
2 2
SET @@global.connect_timeout = -1024; SET @@global.connect_timeout = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect connect_timeout value: '0' Warning 1292 Truncated incorrect connect_timeout value: '-1024'
SELECT @@global.connect_timeout; SELECT @@global.connect_timeout;
@@global.connect_timeout @@global.connect_timeout
2 2
......
...@@ -64,6 +64,8 @@ SELECT @@global.default_week_format; ...@@ -64,6 +64,8 @@ SELECT @@global.default_week_format;
@@global.default_week_format @@global.default_week_format
7 7
SET @@global.default_week_format = -1024; SET @@global.default_week_format = -1024;
Warnings:
Warning 1292 Truncated incorrect default_week_format value: '-1024'
SELECT @@global.default_week_format; SELECT @@global.default_week_format;
@@global.default_week_format @@global.default_week_format
0 0
...@@ -100,6 +102,8 @@ SELECT @@session.default_week_format; ...@@ -100,6 +102,8 @@ SELECT @@session.default_week_format;
@@session.default_week_format @@session.default_week_format
7 7
SET @@session.default_week_format = -2; SET @@session.default_week_format = -2;
Warnings:
Warning 1292 Truncated incorrect default_week_format value: '-2'
SELECT @@session.default_week_format; SELECT @@session.default_week_format;
@@session.default_week_format @@session.default_week_format
0 0
......
...@@ -35,7 +35,7 @@ SELECT @@global.delayed_insert_timeout; ...@@ -35,7 +35,7 @@ SELECT @@global.delayed_insert_timeout;
1 1
SET @@global.delayed_insert_timeout = -1024; SET @@global.delayed_insert_timeout = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect delayed_insert_timeout value: '0' Warning 1292 Truncated incorrect delayed_insert_timeout value: '-1024'
SELECT @@global.delayed_insert_timeout; SELECT @@global.delayed_insert_timeout;
@@global.delayed_insert_timeout @@global.delayed_insert_timeout
1 1
......
...@@ -78,6 +78,8 @@ SELECT @@global.div_precision_increment; ...@@ -78,6 +78,8 @@ SELECT @@global.div_precision_increment;
@@global.div_precision_increment @@global.div_precision_increment
30 30
SET @@global.div_precision_increment = -1024; SET @@global.div_precision_increment = -1024;
Warnings:
Warning 1292 Truncated incorrect div_precision_increment value: '-1024'
SELECT @@global.div_precision_increment; SELECT @@global.div_precision_increment;
@@global.div_precision_increment @@global.div_precision_increment
0 0
...@@ -100,6 +102,8 @@ SELECT @@session.div_precision_increment; ...@@ -100,6 +102,8 @@ SELECT @@session.div_precision_increment;
@@session.div_precision_increment @@session.div_precision_increment
30 30
SET @@session.div_precision_increment = -2; SET @@session.div_precision_increment = -2;
Warnings:
Warning 1292 Truncated incorrect div_precision_increment value: '-2'
SELECT @@session.div_precision_increment; SELECT @@session.div_precision_increment;
@@session.div_precision_increment @@session.div_precision_increment
0 0
......
...@@ -32,6 +32,8 @@ SELECT @@global.expire_logs_days; ...@@ -32,6 +32,8 @@ SELECT @@global.expire_logs_days;
21 21
'#--------------------FN_DYNVARS_029_04-------------------------#' '#--------------------FN_DYNVARS_029_04-------------------------#'
SET @@global.expire_logs_days = -1; SET @@global.expire_logs_days = -1;
Warnings:
Warning 1292 Truncated incorrect expire_logs_days value: '-1'
SELECT @@global.expire_logs_days; SELECT @@global.expire_logs_days;
@@global.expire_logs_days @@global.expire_logs_days
0 0
...@@ -53,6 +55,8 @@ SELECT @@global.expire_logs_days; ...@@ -53,6 +55,8 @@ SELECT @@global.expire_logs_days;
@@global.expire_logs_days @@global.expire_logs_days
99 99
SET @@global.expire_logs_days = -1024; SET @@global.expire_logs_days = -1024;
Warnings:
Warning 1292 Truncated incorrect expire_logs_days value: '-1024'
SELECT @@global.expire_logs_days; SELECT @@global.expire_logs_days;
@@global.expire_logs_days @@global.expire_logs_days
0 0
......
...@@ -65,7 +65,7 @@ SELECT @@global.group_concat_max_len; ...@@ -65,7 +65,7 @@ SELECT @@global.group_concat_max_len;
4 4
SET @@global.group_concat_max_len = -1024; SET @@global.group_concat_max_len = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect group_concat_max_len value: '0' Warning 1292 Truncated incorrect group_concat_max_len value: '-1024'
SELECT @@global.group_concat_max_len; SELECT @@global.group_concat_max_len;
@@global.group_concat_max_len @@global.group_concat_max_len
4 4
...@@ -91,7 +91,7 @@ SELECT @@session.group_concat_max_len; ...@@ -91,7 +91,7 @@ SELECT @@session.group_concat_max_len;
4 4
SET @@session.group_concat_max_len = -2; SET @@session.group_concat_max_len = -2;
Warnings: Warnings:
Warning 1292 Truncated incorrect group_concat_max_len value: '0' Warning 1292 Truncated incorrect group_concat_max_len value: '-2'
SELECT @@session.group_concat_max_len; SELECT @@session.group_concat_max_len;
@@session.group_concat_max_len @@session.group_concat_max_len
4 4
......
...@@ -61,7 +61,7 @@ SELECT @@global.interactive_timeout; ...@@ -61,7 +61,7 @@ SELECT @@global.interactive_timeout;
1 1
SET @@global.interactive_timeout = -1024; SET @@global.interactive_timeout = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect interactive_timeout value: '0' Warning 1292 Truncated incorrect interactive_timeout value: '-1024'
SELECT @@global.interactive_timeout; SELECT @@global.interactive_timeout;
@@global.interactive_timeout @@global.interactive_timeout
1 1
...@@ -89,7 +89,7 @@ SELECT @@session.interactive_timeout; ...@@ -89,7 +89,7 @@ SELECT @@session.interactive_timeout;
1 1
SET @@session.interactive_timeout = -2; SET @@session.interactive_timeout = -2;
Warnings: Warnings:
Warning 1292 Truncated incorrect interactive_timeout value: '0' Warning 1292 Truncated incorrect interactive_timeout value: '-2'
SELECT @@session.interactive_timeout; SELECT @@session.interactive_timeout;
@@session.interactive_timeout @@session.interactive_timeout
1 1
......
...@@ -76,7 +76,7 @@ SELECT @@global.max_allowed_packet; ...@@ -76,7 +76,7 @@ SELECT @@global.max_allowed_packet;
1024 1024
SET @@global.max_allowed_packet = -1024; SET @@global.max_allowed_packet = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect max_allowed_packet value: '0' Warning 1292 Truncated incorrect max_allowed_packet value: '-1024'
SELECT @@global.max_allowed_packet; SELECT @@global.max_allowed_packet;
@@global.max_allowed_packet @@global.max_allowed_packet
1024 1024
......
...@@ -39,7 +39,7 @@ SELECT @@global.max_binlog_size; ...@@ -39,7 +39,7 @@ SELECT @@global.max_binlog_size;
'#--------------------FN_DYNVARS_072_04-------------------------#' '#--------------------FN_DYNVARS_072_04-------------------------#'
SET @@global.max_binlog_size = -1; SET @@global.max_binlog_size = -1;
Warnings: Warnings:
Warning 1292 Truncated incorrect max_binlog_size value: '0' Warning 1292 Truncated incorrect max_binlog_size value: '-1'
SELECT @@global.max_binlog_size; SELECT @@global.max_binlog_size;
@@global.max_binlog_size @@global.max_binlog_size
4096 4096
...@@ -56,7 +56,7 @@ SELECT @@global.max_binlog_size; ...@@ -56,7 +56,7 @@ SELECT @@global.max_binlog_size;
1073741824 1073741824
SET @@global.max_binlog_size = -1024; SET @@global.max_binlog_size = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect max_binlog_size value: '0' Warning 1292 Truncated incorrect max_binlog_size value: '-1024'
SELECT @@global.max_binlog_size; SELECT @@global.max_binlog_size;
@@global.max_binlog_size @@global.max_binlog_size
4096 4096
......
...@@ -39,7 +39,7 @@ SELECT @@global.max_connections; ...@@ -39,7 +39,7 @@ SELECT @@global.max_connections;
'#--------------------FN_DYNVARS_074_04-------------------------#' '#--------------------FN_DYNVARS_074_04-------------------------#'
SET @@global.max_connections = -1; SET @@global.max_connections = -1;
Warnings: Warnings:
Warning 1292 Truncated incorrect max_connections value: '0' Warning 1292 Truncated incorrect max_connections value: '-1'
SELECT @@global.max_connections; SELECT @@global.max_connections;
@@global.max_connections @@global.max_connections
1 1
...@@ -56,7 +56,7 @@ SELECT @@global.max_connections; ...@@ -56,7 +56,7 @@ SELECT @@global.max_connections;
100000 100000
SET @@global.max_connections = -1024; SET @@global.max_connections = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect max_connections value: '0' Warning 1292 Truncated incorrect max_connections value: '-1024'
SELECT @@global.max_connections; SELECT @@global.max_connections;
@@global.max_connections @@global.max_connections
1 1
......
...@@ -76,10 +76,14 @@ SELECT @@session.max_delayed_threads; ...@@ -76,10 +76,14 @@ SELECT @@session.max_delayed_threads;
16383 16383
'#------------------FN_DYNVARS_075_05-----------------------#' '#------------------FN_DYNVARS_075_05-----------------------#'
SET @@global.max_delayed_threads = -1024; SET @@global.max_delayed_threads = -1024;
Warnings:
Warning 1292 Truncated incorrect max_delayed_threads value: '-1024'
SELECT @@global.max_delayed_threads; SELECT @@global.max_delayed_threads;
@@global.max_delayed_threads @@global.max_delayed_threads
0 0
SET @@global.max_delayed_threads = -1; SET @@global.max_delayed_threads = -1;
Warnings:
Warning 1292 Truncated incorrect max_delayed_threads value: '-1'
SELECT @@global.max_delayed_threads; SELECT @@global.max_delayed_threads;
@@global.max_delayed_threads @@global.max_delayed_threads
0 0
......
...@@ -63,10 +63,14 @@ SELECT @@session.max_error_count; ...@@ -63,10 +63,14 @@ SELECT @@session.max_error_count;
65534 65534
'#------------------FN_DYNVARS_076_05-----------------------#' '#------------------FN_DYNVARS_076_05-----------------------#'
SET @@global.max_error_count = -1; SET @@global.max_error_count = -1;
Warnings:
Warning 1292 Truncated incorrect max_error_count value: '-1'
SELECT @@global.max_error_count; SELECT @@global.max_error_count;
@@global.max_error_count @@global.max_error_count
0 0
SET @@global.max_error_count = -1024; SET @@global.max_error_count = -1024;
Warnings:
Warning 1292 Truncated incorrect max_error_count value: '-1024'
SELECT @@global.max_error_count; SELECT @@global.max_error_count;
@@global.max_error_count @@global.max_error_count
0 0
...@@ -93,6 +97,8 @@ SELECT @@global.max_error_count; ...@@ -93,6 +97,8 @@ SELECT @@global.max_error_count;
@@global.max_error_count @@global.max_error_count
65535 65535
SET @@session.max_error_count = -1; SET @@session.max_error_count = -1;
Warnings:
Warning 1292 Truncated incorrect max_error_count value: '-1'
SELECT @@session.max_error_count; SELECT @@session.max_error_count;
@@session.max_error_count @@session.max_error_count
0 0
...@@ -102,6 +108,8 @@ SELECT @@session.max_error_count; ...@@ -102,6 +108,8 @@ SELECT @@session.max_error_count;
@@session.max_error_count @@session.max_error_count
65535 65535
SET @@session.max_error_count = -2; SET @@session.max_error_count = -2;
Warnings:
Warning 1292 Truncated incorrect max_error_count value: '-2'
SELECT @@session.max_error_count; SELECT @@session.max_error_count;
@@session.max_error_count @@session.max_error_count
0 0
......
...@@ -77,10 +77,14 @@ SELECT @@session.max_insert_delayed_threads; ...@@ -77,10 +77,14 @@ SELECT @@session.max_insert_delayed_threads;
16383 16383
'#------------------FN_DYNVARS_078_05-----------------------#' '#------------------FN_DYNVARS_078_05-----------------------#'
SET @@global.max_insert_delayed_threads = -1024; SET @@global.max_insert_delayed_threads = -1024;
Warnings:
Warning 1292 Truncated incorrect max_insert_delayed_threads value: '-1024'
SELECT @@global.max_insert_delayed_threads; SELECT @@global.max_insert_delayed_threads;
@@global.max_insert_delayed_threads @@global.max_insert_delayed_threads
0 0
SET @@global.max_insert_delayed_threads = -1; SET @@global.max_insert_delayed_threads = -1;
Warnings:
Warning 1292 Truncated incorrect max_insert_delayed_threads value: '-1'
SELECT @@global.max_insert_delayed_threads; SELECT @@global.max_insert_delayed_threads;
@@global.max_insert_delayed_threads @@global.max_insert_delayed_threads
0 0
......
...@@ -71,7 +71,7 @@ SELECT @@session.max_length_for_sort_data; ...@@ -71,7 +71,7 @@ SELECT @@session.max_length_for_sort_data;
'#------------------FN_DYNVARS_080_05-----------------------#' '#------------------FN_DYNVARS_080_05-----------------------#'
SET @@global.max_length_for_sort_data = -1024; SET @@global.max_length_for_sort_data = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect max_length_for_sort_data value: '0' Warning 1292 Truncated incorrect max_length_for_sort_data value: '-1024'
SELECT @@global.max_length_for_sort_data; SELECT @@global.max_length_for_sort_data;
@@global.max_length_for_sort_data @@global.max_length_for_sort_data
4 4
...@@ -111,7 +111,7 @@ SELECT @@session.max_length_for_sort_data; ...@@ -111,7 +111,7 @@ SELECT @@session.max_length_for_sort_data;
8388608 8388608
SET @@session.max_length_for_sort_data = -1; SET @@session.max_length_for_sort_data = -1;
Warnings: Warnings:
Warning 1292 Truncated incorrect max_length_for_sort_data value: '0' Warning 1292 Truncated incorrect max_length_for_sort_data value: '-1'
SELECT @@session.max_length_for_sort_data; SELECT @@session.max_length_for_sort_data;
@@session.max_length_for_sort_data @@session.max_length_for_sort_data
4 4
......
...@@ -36,6 +36,8 @@ SELECT @@global.max_prepared_stmt_count; ...@@ -36,6 +36,8 @@ SELECT @@global.max_prepared_stmt_count;
65535 65535
'#--------------------FN_DYNVARS_081_04-------------------------#' '#--------------------FN_DYNVARS_081_04-------------------------#'
SET @@global.max_prepared_stmt_count = -1; SET @@global.max_prepared_stmt_count = -1;
Warnings:
Warning 1292 Truncated incorrect max_prepared_stmt_count value: '-1'
SELECT @@global.max_prepared_stmt_count; SELECT @@global.max_prepared_stmt_count;
@@global.max_prepared_stmt_count @@global.max_prepared_stmt_count
0 0
...@@ -51,6 +53,8 @@ SELECT @@global.max_prepared_stmt_count; ...@@ -51,6 +53,8 @@ SELECT @@global.max_prepared_stmt_count;
@@global.max_prepared_stmt_count @@global.max_prepared_stmt_count
1048576 1048576
SET @@global.max_prepared_stmt_count = -1024; SET @@global.max_prepared_stmt_count = -1024;
Warnings:
Warning 1292 Truncated incorrect max_prepared_stmt_count value: '-1024'
SELECT @@global.max_prepared_stmt_count; SELECT @@global.max_prepared_stmt_count;
@@global.max_prepared_stmt_count @@global.max_prepared_stmt_count
0 0
......
...@@ -38,6 +38,8 @@ SELECT @@global.max_relay_log_size; ...@@ -38,6 +38,8 @@ SELECT @@global.max_relay_log_size;
'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; 'Bug# 34877: Invalid Values are coming in variable on assigning valid values';
'#--------------------FN_DYNVARS_082_04-------------------------#' '#--------------------FN_DYNVARS_082_04-------------------------#'
SET @@global.max_relay_log_size = -1; SET @@global.max_relay_log_size = -1;
Warnings:
Warning 1292 Truncated incorrect max_relay_log_size value: '-1'
SELECT @@global.max_relay_log_size; SELECT @@global.max_relay_log_size;
@@global.max_relay_log_size @@global.max_relay_log_size
0 0
...@@ -53,6 +55,8 @@ SELECT @@global.max_relay_log_size; ...@@ -53,6 +55,8 @@ SELECT @@global.max_relay_log_size;
@@global.max_relay_log_size @@global.max_relay_log_size
1073741824 1073741824
SET @@global.max_relay_log_size = -1024; SET @@global.max_relay_log_size = -1024;
Warnings:
Warning 1292 Truncated incorrect max_relay_log_size value: '-1024'
SELECT @@global.max_relay_log_size; SELECT @@global.max_relay_log_size;
@@global.max_relay_log_size @@global.max_relay_log_size
0 0
......
...@@ -71,7 +71,7 @@ SELECT @@session.max_sort_length; ...@@ -71,7 +71,7 @@ SELECT @@session.max_sort_length;
'#------------------FN_DYNVARS_084_05-----------------------#' '#------------------FN_DYNVARS_084_05-----------------------#'
SET @@global.max_sort_length = -1024; SET @@global.max_sort_length = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect max_sort_length value: '0' Warning 1292 Truncated incorrect max_sort_length value: '-1024'
SELECT @@global.max_sort_length; SELECT @@global.max_sort_length;
@@global.max_sort_length @@global.max_sort_length
4 4
...@@ -111,7 +111,7 @@ SELECT @@session.max_sort_length; ...@@ -111,7 +111,7 @@ SELECT @@session.max_sort_length;
8388608 8388608
SET @@session.max_sort_length = -1; SET @@session.max_sort_length = -1;
Warnings: Warnings:
Warning 1292 Truncated incorrect max_sort_length value: '0' Warning 1292 Truncated incorrect max_sort_length value: '-1'
SELECT @@session.max_sort_length; SELECT @@session.max_sort_length;
@@session.max_sort_length @@session.max_sort_length
4 4
......
...@@ -74,6 +74,8 @@ SELECT @@session.max_sp_recursion_depth; ...@@ -74,6 +74,8 @@ SELECT @@session.max_sp_recursion_depth;
150 150
'#------------------FN_DYNVARS_085_05-----------------------#' '#------------------FN_DYNVARS_085_05-----------------------#'
SET @@global.max_sp_recursion_depth = -1024; SET @@global.max_sp_recursion_depth = -1024;
Warnings:
Warning 1292 Truncated incorrect max_sp_recursion_depth value: '-1024'
SELECT @@global.max_sp_recursion_depth; SELECT @@global.max_sp_recursion_depth;
@@global.max_sp_recursion_depth @@global.max_sp_recursion_depth
0 0
...@@ -84,6 +86,8 @@ SELECT @@global.max_sp_recursion_depth; ...@@ -84,6 +86,8 @@ SELECT @@global.max_sp_recursion_depth;
@@global.max_sp_recursion_depth @@global.max_sp_recursion_depth
255 255
SET @@global.max_sp_recursion_depth = -1; SET @@global.max_sp_recursion_depth = -1;
Warnings:
Warning 1292 Truncated incorrect max_sp_recursion_depth value: '-1'
SELECT @@global.max_sp_recursion_depth; SELECT @@global.max_sp_recursion_depth;
@@global.max_sp_recursion_depth @@global.max_sp_recursion_depth
0 0
...@@ -110,6 +114,8 @@ SELECT @@session.max_sp_recursion_depth; ...@@ -110,6 +114,8 @@ SELECT @@session.max_sp_recursion_depth;
@@session.max_sp_recursion_depth @@session.max_sp_recursion_depth
255 255
SET @@session.max_sp_recursion_depth = -1; SET @@session.max_sp_recursion_depth = -1;
Warnings:
Warning 1292 Truncated incorrect max_sp_recursion_depth value: '-1'
SELECT @@session.max_sp_recursion_depth; SELECT @@session.max_sp_recursion_depth;
@@session.max_sp_recursion_depth @@session.max_sp_recursion_depth
0 0
...@@ -120,6 +126,8 @@ SELECT @@session.max_sp_recursion_depth; ...@@ -120,6 +126,8 @@ SELECT @@session.max_sp_recursion_depth;
@@session.max_sp_recursion_depth @@session.max_sp_recursion_depth
255 255
SET @@session.max_sp_recursion_depth = -001; SET @@session.max_sp_recursion_depth = -001;
Warnings:
Warning 1292 Truncated incorrect max_sp_recursion_depth value: '-1'
SELECT @@session.max_sp_recursion_depth; SELECT @@session.max_sp_recursion_depth;
@@session.max_sp_recursion_depth @@session.max_sp_recursion_depth
0 0
......
...@@ -48,7 +48,7 @@ ERROR HY000: Variable 'myisam_data_pointer_size' is a GLOBAL variable and should ...@@ -48,7 +48,7 @@ ERROR HY000: Variable 'myisam_data_pointer_size' is a GLOBAL variable and should
'#------------------FN_DYNVARS_093_05-----------------------#' '#------------------FN_DYNVARS_093_05-----------------------#'
SET @@global.myisam_data_pointer_size = -1; SET @@global.myisam_data_pointer_size = -1;
Warnings: Warnings:
Warning 1292 Truncated incorrect myisam_data_pointer_size value: '0' Warning 1292 Truncated incorrect myisam_data_pointer_size value: '-1'
SELECT @@global.myisam_data_pointer_size; SELECT @@global.myisam_data_pointer_size;
@@global.myisam_data_pointer_size @@global.myisam_data_pointer_size
2 2
......
...@@ -50,7 +50,7 @@ SELECT @@global.net_buffer_length; ...@@ -50,7 +50,7 @@ SELECT @@global.net_buffer_length;
1024 1024
SET @@global.net_buffer_length = -1024; SET @@global.net_buffer_length = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect net_buffer_length value: '0' Warning 1292 Truncated incorrect net_buffer_length value: '-1024'
SELECT @@global.net_buffer_length; SELECT @@global.net_buffer_length;
@@global.net_buffer_length @@global.net_buffer_length
1024 1024
......
...@@ -61,7 +61,7 @@ SELECT @@global.net_read_timeout; ...@@ -61,7 +61,7 @@ SELECT @@global.net_read_timeout;
1 1
SET @@global.net_read_timeout = -1024; SET @@global.net_read_timeout = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect net_read_timeout value: '0' Warning 1292 Truncated incorrect net_read_timeout value: '-1024'
SELECT @@global.net_read_timeout; SELECT @@global.net_read_timeout;
@@global.net_read_timeout @@global.net_read_timeout
1 1
...@@ -89,7 +89,7 @@ SELECT @@session.net_read_timeout; ...@@ -89,7 +89,7 @@ SELECT @@session.net_read_timeout;
1 1
SET @@session.net_read_timeout = -2; SET @@session.net_read_timeout = -2;
Warnings: Warnings:
Warning 1292 Truncated incorrect net_read_timeout value: '0' Warning 1292 Truncated incorrect net_read_timeout value: '-2'
SELECT @@session.net_read_timeout; SELECT @@session.net_read_timeout;
@@session.net_read_timeout @@session.net_read_timeout
1 1
......
...@@ -61,7 +61,7 @@ SELECT @@global.net_write_timeout; ...@@ -61,7 +61,7 @@ SELECT @@global.net_write_timeout;
1 1
SET @@global.net_write_timeout = -1024; SET @@global.net_write_timeout = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect net_write_timeout value: '0' Warning 1292 Truncated incorrect net_write_timeout value: '-1024'
SELECT @@global.net_write_timeout; SELECT @@global.net_write_timeout;
@@global.net_write_timeout @@global.net_write_timeout
1 1
...@@ -89,7 +89,7 @@ SELECT @@session.net_write_timeout; ...@@ -89,7 +89,7 @@ SELECT @@session.net_write_timeout;
1 1
SET @@session.net_write_timeout = -2; SET @@session.net_write_timeout = -2;
Warnings: Warnings:
Warning 1292 Truncated incorrect net_write_timeout value: '0' Warning 1292 Truncated incorrect net_write_timeout value: '-2'
SELECT @@session.net_write_timeout; SELECT @@session.net_write_timeout;
@@session.net_write_timeout @@session.net_write_timeout
1 1
......
...@@ -81,6 +81,8 @@ ERROR 42000: Incorrect argument type to variable 'optimizer_prune_level' ...@@ -81,6 +81,8 @@ ERROR 42000: Incorrect argument type to variable 'optimizer_prune_level'
SET @@global.optimizer_prune_level = FELSE; SET @@global.optimizer_prune_level = FELSE;
ERROR 42000: Incorrect argument type to variable 'optimizer_prune_level' ERROR 42000: Incorrect argument type to variable 'optimizer_prune_level'
SET @@global.optimizer_prune_level = -1024; SET @@global.optimizer_prune_level = -1024;
Warnings:
Warning 1292 Truncated incorrect optimizer_prune_level value: '-1024'
SELECT @@global.optimizer_prune_level; SELECT @@global.optimizer_prune_level;
@@global.optimizer_prune_level @@global.optimizer_prune_level
0 0
...@@ -107,6 +109,8 @@ ERROR 42000: Incorrect argument type to variable 'optimizer_prune_level' ...@@ -107,6 +109,8 @@ ERROR 42000: Incorrect argument type to variable 'optimizer_prune_level'
SET @@session.optimizer_prune_level = 'OFN'; SET @@session.optimizer_prune_level = 'OFN';
ERROR 42000: Incorrect argument type to variable 'optimizer_prune_level' ERROR 42000: Incorrect argument type to variable 'optimizer_prune_level'
SET @@session.optimizer_prune_level = -2; SET @@session.optimizer_prune_level = -2;
Warnings:
Warning 1292 Truncated incorrect optimizer_prune_level value: '-2'
SELECT @@session.optimizer_prune_level; SELECT @@session.optimizer_prune_level;
@@session.optimizer_prune_level @@session.optimizer_prune_level
0 0
......
...@@ -72,6 +72,8 @@ SELECT @@global.optimizer_search_depth; ...@@ -72,6 +72,8 @@ SELECT @@global.optimizer_search_depth;
@@global.optimizer_search_depth @@global.optimizer_search_depth
63 63
SET @@global.optimizer_search_depth = -1; SET @@global.optimizer_search_depth = -1;
Warnings:
Warning 1292 Truncated incorrect optimizer_search_depth value: '-1'
SELECT @@global.optimizer_search_depth; SELECT @@global.optimizer_search_depth;
@@global.optimizer_search_depth @@global.optimizer_search_depth
0 0
...@@ -98,6 +100,8 @@ SELECT @@session.optimizer_search_depth; ...@@ -98,6 +100,8 @@ SELECT @@session.optimizer_search_depth;
@@session.optimizer_search_depth @@session.optimizer_search_depth
63 63
SET @@session.optimizer_search_depth = -2; SET @@session.optimizer_search_depth = -2;
Warnings:
Warning 1292 Truncated incorrect optimizer_search_depth value: '-2'
SELECT @@session.optimizer_search_depth; SELECT @@session.optimizer_search_depth;
@@session.optimizer_search_depth @@session.optimizer_search_depth
0 0
......
...@@ -77,7 +77,7 @@ SELECT @@global.preload_buffer_size; ...@@ -77,7 +77,7 @@ SELECT @@global.preload_buffer_size;
1024 1024
SET @@global.preload_buffer_size = -1; SET @@global.preload_buffer_size = -1;
Warnings: Warnings:
Warning 1292 Truncated incorrect preload_buffer_size value: '0' Warning 1292 Truncated incorrect preload_buffer_size value: '-1'
SELECT @@global.preload_buffer_size; SELECT @@global.preload_buffer_size;
@@global.preload_buffer_size @@global.preload_buffer_size
1024 1024
...@@ -111,7 +111,7 @@ SELECT @@session.preload_buffer_size; ...@@ -111,7 +111,7 @@ SELECT @@session.preload_buffer_size;
1024 1024
SET @@session.preload_buffer_size = -2; SET @@session.preload_buffer_size = -2;
Warnings: Warnings:
Warning 1292 Truncated incorrect preload_buffer_size value: '0' Warning 1292 Truncated incorrect preload_buffer_size value: '-2'
SELECT @@session.preload_buffer_size; SELECT @@session.preload_buffer_size;
@@session.preload_buffer_size @@session.preload_buffer_size
1024 1024
......
...@@ -803,6 +803,8 @@ select @@max_prepared_stmt_count; ...@@ -803,6 +803,8 @@ select @@max_prepared_stmt_count;
@@max_prepared_stmt_count @@max_prepared_stmt_count
16382 16382
set global max_prepared_stmt_count=-1; set global max_prepared_stmt_count=-1;
Warnings:
Warning 1292 Truncated incorrect max_prepared_stmt_count value: '-1'
select @@max_prepared_stmt_count; select @@max_prepared_stmt_count;
@@max_prepared_stmt_count @@max_prepared_stmt_count
0 0
......
...@@ -81,7 +81,7 @@ SELECT @@global.read_buffer_size= 8200 OR @@global.read_buffer_size= 8228 ; ...@@ -81,7 +81,7 @@ SELECT @@global.read_buffer_size= 8200 OR @@global.read_buffer_size= 8228 ;
1 1
SET @@global.read_buffer_size = -1024; SET @@global.read_buffer_size = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect read_buffer_size value: '0' Warning 1292 Truncated incorrect read_buffer_size value: '-1024'
SELECT @@global.read_buffer_size= 8200 OR @@global.read_buffer_size= 8228 ; SELECT @@global.read_buffer_size= 8200 OR @@global.read_buffer_size= 8228 ;
@@global.read_buffer_size= 8200 OR @@global.read_buffer_size= 8228 @@global.read_buffer_size= 8200 OR @@global.read_buffer_size= 8228
1 1
...@@ -107,7 +107,7 @@ SELECT @@session.read_buffer_size= 8200 OR @@session.read_buffer_size= 8228 ; ...@@ -107,7 +107,7 @@ SELECT @@session.read_buffer_size= 8200 OR @@session.read_buffer_size= 8228 ;
1 1
SET @@session.read_buffer_size = -2; SET @@session.read_buffer_size = -2;
Warnings: Warnings:
Warning 1292 Truncated incorrect read_buffer_size value: '0' Warning 1292 Truncated incorrect read_buffer_size value: '-2'
SELECT @@session.read_buffer_size= 8200 OR @@session.read_buffer_size= 8228 ; SELECT @@session.read_buffer_size= 8200 OR @@session.read_buffer_size= 8228 ;
@@session.read_buffer_size= 8200 OR @@session.read_buffer_size= 8228 @@session.read_buffer_size= 8200 OR @@session.read_buffer_size= 8228
1 1
......
...@@ -83,7 +83,7 @@ SELECT @@global.read_rnd_buffer_size= 8200 OR @@global.read_rnd_buffer_size= 822 ...@@ -83,7 +83,7 @@ SELECT @@global.read_rnd_buffer_size= 8200 OR @@global.read_rnd_buffer_size= 822
1 1
SET @@global.read_rnd_buffer_size = -1024; SET @@global.read_rnd_buffer_size = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect read_rnd_buffer_size value: '0' Warning 1292 Truncated incorrect read_rnd_buffer_size value: '-1024'
SELECT @@global.read_rnd_buffer_size= 8200 OR @@global.read_rnd_buffer_size= 8228; SELECT @@global.read_rnd_buffer_size= 8200 OR @@global.read_rnd_buffer_size= 8228;
@@global.read_rnd_buffer_size= 8200 OR @@global.read_rnd_buffer_size= 8228 @@global.read_rnd_buffer_size= 8200 OR @@global.read_rnd_buffer_size= 8228
1 1
...@@ -109,7 +109,7 @@ SELECT @@session.read_rnd_buffer_size= 8200 OR @@session.read_rnd_buffer_size= 8 ...@@ -109,7 +109,7 @@ SELECT @@session.read_rnd_buffer_size= 8200 OR @@session.read_rnd_buffer_size= 8
1 1
SET @@session.read_rnd_buffer_size = -2; SET @@session.read_rnd_buffer_size = -2;
Warnings: Warnings:
Warning 1292 Truncated incorrect read_rnd_buffer_size value: '0' Warning 1292 Truncated incorrect read_rnd_buffer_size value: '-2'
SELECT @@session.read_rnd_buffer_size= 8200 OR @@session.read_rnd_buffer_size= 8228; SELECT @@session.read_rnd_buffer_size= 8200 OR @@session.read_rnd_buffer_size= 8228;
@@session.read_rnd_buffer_size= 8200 OR @@session.read_rnd_buffer_size= 8228 @@session.read_rnd_buffer_size= 8200 OR @@session.read_rnd_buffer_size= 8228
1 1
......
...@@ -58,13 +58,13 @@ ERROR HY000: Variable 'slave_net_timeout' is a GLOBAL variable and should be set ...@@ -58,13 +58,13 @@ ERROR HY000: Variable 'slave_net_timeout' is a GLOBAL variable and should be set
'#------------------FN_DYNVARS_146_05-----------------------#' '#------------------FN_DYNVARS_146_05-----------------------#'
SET @@global.slave_net_timeout = -1; SET @@global.slave_net_timeout = -1;
Warnings: Warnings:
Warning 1292 Truncated incorrect slave_net_timeout value: '0' Warning 1292 Truncated incorrect slave_net_timeout value: '-1'
SELECT @@global.slave_net_timeout; SELECT @@global.slave_net_timeout;
@@global.slave_net_timeout @@global.slave_net_timeout
1 1
SET @@global.slave_net_timeout = -2147483648; SET @@global.slave_net_timeout = -2147483648;
Warnings: Warnings:
Warning 1292 Truncated incorrect slave_net_timeout value: '0' Warning 1292 Truncated incorrect slave_net_timeout value: '-2147483648'
SELECT @@global.slave_net_timeout; SELECT @@global.slave_net_timeout;
@@global.slave_net_timeout @@global.slave_net_timeout
1 1
......
...@@ -36,6 +36,8 @@ SELECT @@global.slow_launch_time; ...@@ -36,6 +36,8 @@ SELECT @@global.slow_launch_time;
65536 65536
'#--------------------FN_DYNVARS_150_04-------------------------#' '#--------------------FN_DYNVARS_150_04-------------------------#'
SET @@global.slow_launch_time = -1; SET @@global.slow_launch_time = -1;
Warnings:
Warning 1292 Truncated incorrect slow_launch_time value: '-1'
SELECT @@global.slow_launch_time; SELECT @@global.slow_launch_time;
@@global.slow_launch_time @@global.slow_launch_time
0 0
...@@ -57,6 +59,8 @@ SELECT @@global.slow_launch_time; ...@@ -57,6 +59,8 @@ SELECT @@global.slow_launch_time;
@@global.slow_launch_time @@global.slow_launch_time
31536000 31536000
SET @@global.slow_launch_time = -1024; SET @@global.slow_launch_time = -1024;
Warnings:
Warning 1292 Truncated incorrect slow_launch_time value: '-1024'
SELECT @@global.slow_launch_time; SELECT @@global.slow_launch_time;
@@global.slow_launch_time @@global.slow_launch_time
0 0
......
...@@ -45,7 +45,7 @@ SELECT @@global.table_definition_cache; ...@@ -45,7 +45,7 @@ SELECT @@global.table_definition_cache;
256 256
SET @@global.table_definition_cache = -1024; SET @@global.table_definition_cache = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect table_definition_cache value: '0' Warning 1292 Truncated incorrect table_definition_cache value: '-1024'
SELECT @@global.table_definition_cache; SELECT @@global.table_definition_cache;
@@global.table_definition_cache @@global.table_definition_cache
256 256
......
...@@ -37,13 +37,13 @@ SELECT @@global.table_lock_wait_timeout ; ...@@ -37,13 +37,13 @@ SELECT @@global.table_lock_wait_timeout ;
'#--------------------FN_DYNVARS_001_04-------------------------#' '#--------------------FN_DYNVARS_001_04-------------------------#'
SET @@global.table_lock_wait_timeout = -1; SET @@global.table_lock_wait_timeout = -1;
Warnings: Warnings:
Warning 1292 Truncated incorrect table_lock_wait_timeout value: '0' Warning 1292 Truncated incorrect table_lock_wait_timeout value: '-1'
SET @@global.table_lock_wait_timeout= 100000000000; SET @@global.table_lock_wait_timeout= 100000000000;
Warnings: Warnings:
Warning 1292 Truncated incorrect table_lock_wait_timeout value: '100000000000' Warning 1292 Truncated incorrect table_lock_wait_timeout value: '100000000000'
SET @@global.table_lock_wait_timeout= -1024; SET @@global.table_lock_wait_timeout= -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect table_lock_wait_timeout value: '0' Warning 1292 Truncated incorrect table_lock_wait_timeout value: '-1024'
SET @@global.table_lock_wait_timeout= 0; SET @@global.table_lock_wait_timeout= 0;
Warnings: Warnings:
Warning 1292 Truncated incorrect table_lock_wait_timeout value: '0' Warning 1292 Truncated incorrect table_lock_wait_timeout value: '0'
......
...@@ -39,7 +39,7 @@ SELECT @@global.table_open_cache ; ...@@ -39,7 +39,7 @@ SELECT @@global.table_open_cache ;
'#--------------------FN_DYNVARS_001_04-------------------------#' '#--------------------FN_DYNVARS_001_04-------------------------#'
SET @@global.table_open_cache = -1; SET @@global.table_open_cache = -1;
Warnings: Warnings:
Warning 1292 Truncated incorrect table_open_cache value: '0' Warning 1292 Truncated incorrect table_open_cache value: '-1'
SELECT @@global.table_open_cache ; SELECT @@global.table_open_cache ;
@@global.table_open_cache @@global.table_open_cache
1 1
...@@ -51,7 +51,7 @@ SELECT @@global.table_open_cache ; ...@@ -51,7 +51,7 @@ SELECT @@global.table_open_cache ;
524288 524288
SET @@global.table_open_cache = -1024; SET @@global.table_open_cache = -1024;
Warnings: Warnings:
Warning 1292 Truncated incorrect table_open_cache value: '0' Warning 1292 Truncated incorrect table_open_cache value: '-1024'
SELECT @@global.table_open_cache ; SELECT @@global.table_open_cache ;
@@global.table_open_cache @@global.table_open_cache
1 1
......
...@@ -703,7 +703,7 @@ VARIABLE_NAME VARIABLE_VALUE ...@@ -703,7 +703,7 @@ VARIABLE_NAME VARIABLE_VALUE
MYISAM_DATA_POINTER_SIZE 7 MYISAM_DATA_POINTER_SIZE 7
SET GLOBAL table_open_cache=-1; SET GLOBAL table_open_cache=-1;
Warnings: Warnings:
Warning 1292 Truncated incorrect table_open_cache value: '0' Warning 1292 Truncated incorrect table_open_cache value: '-1'
SHOW VARIABLES LIKE 'table_open_cache'; SHOW VARIABLES LIKE 'table_open_cache';
Variable_name Value Variable_name Value
table_open_cache 1 table_open_cache 1
...@@ -1337,3 +1337,36 @@ SET @@session.thread_stack= 7; ...@@ -1337,3 +1337,36 @@ SET @@session.thread_stack= 7;
ERROR HY000: Variable 'thread_stack' is a read only variable ERROR HY000: Variable 'thread_stack' is a read only variable
SET @@global.thread_stack= 7; SET @@global.thread_stack= 7;
ERROR HY000: Variable 'thread_stack' is a read only variable ERROR HY000: Variable 'thread_stack' is a read only variable
SELECT @@global.expire_logs_days INTO @old_eld;
SET GLOBAL expire_logs_days = -1;
Warnings:
Warning 1292 Truncated incorrect expire_logs_days value: '-1'
needs to've been adjusted (0)
SELECT @@global.expire_logs_days;
@@global.expire_logs_days
0
SET GLOBAL expire_logs_days = 11;
SET @old_mode=@@sql_mode;
SET SESSION sql_mode = 'TRADITIONAL';
SET GLOBAL expire_logs_days = 100;
ERROR 42000: Variable 'expire_logs_days' can't be set to the value of '100'
needs to be unchanged (11)
SELECT @@global.expire_logs_days;
@@global.expire_logs_days
11
SET SESSION sql_mode = @old_mode;
SET GLOBAL expire_logs_days = 100;
Warnings:
Warning 1292 Truncated incorrect expire_logs_days value: '100'
needs to've been adjusted (99)
SELECT @@global.expire_logs_days;
@@global.expire_logs_days
99
SET GLOBAL expire_logs_days = 11;
SET GLOBAL expire_logs_days = 99;
needs to pass with no warnings (99)
SELECT @@global.expire_logs_days;
@@global.expire_logs_days
99
SET GLOBAL expire_logs_days = @old_eld;
End of 5.1 tests
...@@ -1077,3 +1077,38 @@ SET @@session.thread_stack= 7; ...@@ -1077,3 +1077,38 @@ SET @@session.thread_stack= 7;
--error ER_INCORRECT_GLOBAL_LOCAL_VAR --error ER_INCORRECT_GLOBAL_LOCAL_VAR
SET @@global.thread_stack= 7; SET @@global.thread_stack= 7;
# #
#
# Bug #40657 - assertion with out of range variables and traditional sql_mode
#
SELECT @@global.expire_logs_days INTO @old_eld;
SET GLOBAL expire_logs_days = -1;
--echo needs to've been adjusted (0)
SELECT @@global.expire_logs_days;
SET GLOBAL expire_logs_days = 11;
SET @old_mode=@@sql_mode;
SET SESSION sql_mode = 'TRADITIONAL';
--error ER_WRONG_VALUE_FOR_VAR
SET GLOBAL expire_logs_days = 100;
--echo needs to be unchanged (11)
SELECT @@global.expire_logs_days;
SET SESSION sql_mode = @old_mode;
SET GLOBAL expire_logs_days = 100;
--echo needs to've been adjusted (99)
SELECT @@global.expire_logs_days;
SET GLOBAL expire_logs_days = 11;
SET GLOBAL expire_logs_days = 99;
--echo needs to pass with no warnings (99)
SELECT @@global.expire_logs_days;
# cleanup
SET GLOBAL expire_logs_days = @old_eld;
--echo End of 5.1 tests
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment