Commit 90152c17 authored by Horst Hunger's avatar Horst Hunger

Fix for Bug#36875: Problem was, that there some warnings has been written containing values,

which were determined by the server depending on the os. The solution is to disable warnings in general.
The check of the values only have been done for Linux and Windows. Now, the check has been changed to the check of
ranges (not more concrete values) being near by the expected (set) values.  
parent 5f678447
......@@ -17,9 +17,12 @@
# * Valid & Invalid values #
# * Scope & Access method #
# * Data Integrity #
# Modified: Horst Hunger, 2008-11-28 #
# disabled warnings as they contain the values of this variable, #
# modified the check of the value only checking a range. #
# #
# Reference: http://dev.mysql.com/doc/refman/5.1/en/ #
# server-system-variables.html #
# Reference: #
# http://dev.mysql.com/doc/refman/5.1/en/server-system-variables.html #
# #
###############################################################################
......@@ -37,14 +40,13 @@
# Save initial value #
#############################################################
# due to difference when running on Windows (bug filed)
# due to differences when running on Windows (bug filed)
--source include/not_windows.inc
--disable_warnings
SET @start_global_value = @@global.sort_buffer_size;
SELECT @start_global_value;
SET @start_session_value = @@session.sort_buffer_size;
SELECT @start_session_value;
--echo '#--------------------FN_DYNVARS_151_01-------------------------#'
######################################################################
......@@ -53,11 +55,11 @@ SELECT @start_session_value;
SET @@global.sort_buffer_size = 1000;
SET @@global.sort_buffer_size = DEFAULT;
SELECT @@global.sort_buffer_size= 2097144 OR @@global.sort_buffer_size= 2097116;
SELECT @@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000;
SET @@session.sort_buffer_size = 2000;
SET @@session.sort_buffer_size = DEFAULT;
SELECT @@session.sort_buffer_size= 2097144 OR @@session.sort_buffer_size= 2097116;
SELECT @@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000;
--echo '#--------------------FN_DYNVARS_151_02-------------------------#'
......@@ -66,10 +68,10 @@ SELECT @@session.sort_buffer_size= 2097144 OR @@session.sort_buffer_size= 209711
######################################################################
SET @@global.sort_buffer_size = DEFAULT;
SELECT @@global.sort_buffer_size = 2097144 OR @@global.sort_buffer_size= 2097116;
SELECT @@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000;
SET @@session.sort_buffer_size = DEFAULT;
SELECT @@session.sort_buffer_size = 2097144 OR @@session.sort_buffer_size= 2097116;
SELECT @@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000;
--echo '#--------------------FN_DYNVARS_151_03-------------------------#'
......@@ -78,14 +80,13 @@ SELECT @@session.sort_buffer_size = 2097144 OR @@session.sort_buffer_size= 20971
################################################################################
SET @@global.sort_buffer_size = 32776;
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
SET @@global.sort_buffer_size = 32777;
SELECT @@global.sort_buffer_size= 32777 OR @@global.sort_buffer_size= 32804;
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
SET @@global.sort_buffer_size = 4294967295;
SELECT @@global.sort_buffer_size;
SET @@global.sort_buffer_size = 4294967294;
SELECT @@global.sort_buffer_size;
--echo 'Bug# 34877: Invalid Values are showing in variable on assigning valid values.';
--echo '#--------------------FN_DYNVARS_151_04-------------------------#'
###################################################################################
......@@ -93,9 +94,9 @@ SELECT @@global.sort_buffer_size;
###################################################################################
SET @@session.sort_buffer_size = 32776;
SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804;
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
SET @@session.sort_buffer_size = 32777;
SELECT @@session.sort_buffer_size= 32777 OR @@session.sort_buffer_size= 32804;
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
SET @@session.sort_buffer_size = 4294967295;
SELECT @@session.sort_buffer_size;
SET @@session.sort_buffer_size = 4294967294;
......@@ -108,9 +109,9 @@ SELECT @@session.sort_buffer_size;
##################################################################
SET @@global.sort_buffer_size = 32775;
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
SET @@global.sort_buffer_size = -1024;
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
SET @@global.sort_buffer_size = 4294967296;
SELECT @@global.sort_buffer_size;
--Error ER_PARSE_ERROR
......@@ -121,19 +122,16 @@ SET @@global.sort_buffer_size = test;
SELECT @@global.sort_buffer_size;
SET @@session.sort_buffer_size = 32775;
SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804;
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
SET @@session.sort_buffer_size = -2;
SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804;
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
--Error ER_PARSE_ERROR
SET @@session.sort_buffer_size = 65530.34.;
SET @@session.sort_buffer_size = 4294967296;
SELECT @@session.sort_buffer_size;
--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable';
--Error ER_WRONG_TYPE_FOR_VAR
SET @@session.sort_buffer_size = test;
SELECT @@session.sort_buffer_size;
--echo '#------------------FN_DYNVARS_151_06-----------------------#'
####################################################################
......@@ -141,14 +139,16 @@ SELECT @@session.sort_buffer_size;
####################################################################
SELECT @@global.sort_buffer_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
SELECT @@global.sort_buffer_size = VARIABLE_VALUE FROM
INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
--echo '#------------------FN_DYNVARS_151_07-----------------------#'
####################################################################
# Check if the value in SESSION Table matches value in variable #
####################################################################
SELECT @@session.sort_buffer_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
SELECT @@session.sort_buffer_size = VARIABLE_VALUE FROM
INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
--echo '#------------------FN_DYNVARS_151_08-----------------------#'
......@@ -157,11 +157,9 @@ SELECT @@session.sort_buffer_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.SESSI
####################################################################
SET @@global.sort_buffer_size = TRUE;
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
SET @@global.sort_buffer_size = FALSE;
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
echo 'Bug: Errors should be displayed on assigning TRUE/FALSE to variable';
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
--echo '#---------------------FN_DYNVARS_151_09----------------------#'
####################################################################################
......@@ -171,11 +169,10 @@ echo 'Bug: Errors should be displayed on assigning TRUE/FALSE to variable';
SET @@global.sort_buffer_size = 9000;
SELECT @@sort_buffer_size = @@global.sort_buffer_size;
--echo '#---------------------FN_DYNVARS_151_10----------------------#'
########################################################################################################
# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable #
########################################################################################################
###################################################################################################
# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable#
###################################################################################################
SET @@sort_buffer_size = 9000;
SELECT @@sort_buffer_size = @@local.sort_buffer_size;
......@@ -188,8 +185,7 @@ SELECT @@local.sort_buffer_size = @@session.sort_buffer_size;
###################################################################################
SET sort_buffer_size = 9100;
SELECT @sort_buffer_size= 32776 OR @@sort_buffer_size= 32804;
SELECT @@sort_buffer_size;
SELECT @@sort_buffer_size >= 32776 AND @@sort_buffer_size < 33000;
--Error ER_UNKNOWN_TABLE
SELECT local.sort_buffer_size;
--Error ER_UNKNOWN_TABLE
......@@ -203,11 +199,11 @@ SELECT sort_buffer_size = @@session.sort_buffer_size;
####################################
SET @@global.sort_buffer_size = @start_global_value;
SELECT @@global.sort_buffer_size;
SET @@session.sort_buffer_size = @start_session_value;
SELECT @@session.sort_buffer_size;
--enable_warnings
#############################################################
# END OF sort_buffer_size TESTS #
#############################################################
SET @start_global_value = @@global.sort_buffer_size;
SELECT @start_global_value;
@start_global_value
262144
SET @start_session_value = @@session.sort_buffer_size;
SELECT @start_session_value;
@start_session_value
262144
'#--------------------FN_DYNVARS_151_01-------------------------#'
SET @@global.sort_buffer_size = 1000;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '1000'
SET @@global.sort_buffer_size = DEFAULT;
SELECT @@global.sort_buffer_size= 2097144 OR @@global.sort_buffer_size= 2097116;
@@global.sort_buffer_size= 2097144 OR @@global.sort_buffer_size= 2097116
SELECT @@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000;
@@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000
1
SET @@session.sort_buffer_size = 2000;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '2000'
SET @@session.sort_buffer_size = DEFAULT;
SELECT @@session.sort_buffer_size= 2097144 OR @@session.sort_buffer_size= 2097116;
@@session.sort_buffer_size= 2097144 OR @@session.sort_buffer_size= 2097116
SELECT @@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000;
@@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000
1
'#--------------------FN_DYNVARS_151_02-------------------------#'
SET @@global.sort_buffer_size = DEFAULT;
SELECT @@global.sort_buffer_size = 2097144 OR @@global.sort_buffer_size= 2097116;
@@global.sort_buffer_size = 2097144 OR @@global.sort_buffer_size= 2097116
SELECT @@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000;
@@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000
1
SET @@session.sort_buffer_size = DEFAULT;
SELECT @@session.sort_buffer_size = 2097144 OR @@session.sort_buffer_size= 2097116;
@@session.sort_buffer_size = 2097144 OR @@session.sort_buffer_size= 2097116
SELECT @@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000;
@@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000
1
'#--------------------FN_DYNVARS_151_03-------------------------#'
SET @@global.sort_buffer_size = 32776;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32776'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = 32777;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32777'
SELECT @@global.sort_buffer_size= 32777 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32777 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = 4294967295;
SELECT @@global.sort_buffer_size;
......@@ -51,19 +37,14 @@ SET @@global.sort_buffer_size = 4294967294;
SELECT @@global.sort_buffer_size;
@@global.sort_buffer_size
4294967294
'Bug# 34877: Invalid Values are showing in variable on assigning valid values.';
'#--------------------FN_DYNVARS_151_04-------------------------#'
SET @@session.sort_buffer_size = 32776;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32776'
SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804;
@@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
@@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000
1
SET @@session.sort_buffer_size = 32777;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32777'
SELECT @@session.sort_buffer_size= 32777 OR @@session.sort_buffer_size= 32804;
@@session.sort_buffer_size= 32777 OR @@session.sort_buffer_size= 32804
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
@@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000
1
SET @@session.sort_buffer_size = 4294967295;
SELECT @@session.sort_buffer_size;
......@@ -75,20 +56,14 @@ SELECT @@session.sort_buffer_size;
4294967294
'#------------------FN_DYNVARS_151_05-----------------------#'
SET @@global.sort_buffer_size = 32775;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32775'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = -1024;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '0'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = 4294967296;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '4294967296'
SELECT @@global.sort_buffer_size;
@@global.sort_buffer_size
4294967295
......@@ -103,64 +78,47 @@ SELECT @@global.sort_buffer_size;
@@global.sort_buffer_size
4294967295
SET @@session.sort_buffer_size = 32775;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32775'
SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804;
@@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
@@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000
1
SET @@session.sort_buffer_size = -2;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '0'
SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804;
@@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
@@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000
1
SET @@session.sort_buffer_size = 65530.34.;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '.' at line 1
SET @@session.sort_buffer_size = 4294967296;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '4294967296'
SELECT @@session.sort_buffer_size;
@@session.sort_buffer_size
4294967295
'Bug # 34837: Errors are not coming on assigning invalid values to variable';
SET @@session.sort_buffer_size = test;
ERROR 42000: Incorrect argument type to variable 'sort_buffer_size'
SELECT @@session.sort_buffer_size;
@@session.sort_buffer_size
4294967295
'#------------------FN_DYNVARS_151_06-----------------------#'
SELECT @@global.sort_buffer_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
SELECT @@global.sort_buffer_size = VARIABLE_VALUE FROM
INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
@@global.sort_buffer_size = VARIABLE_VALUE
1
'#------------------FN_DYNVARS_151_07-----------------------#'
SELECT @@session.sort_buffer_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
SELECT @@session.sort_buffer_size = VARIABLE_VALUE FROM
INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
@@session.sort_buffer_size = VARIABLE_VALUE
1
'#------------------FN_DYNVARS_151_08-----------------------#'
SET @@global.sort_buffer_size = TRUE;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '1'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = FALSE;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '0'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
'Bug: Errors should be displayed on assigning TRUE/FALSE to variable'
'#---------------------FN_DYNVARS_151_09----------------------#'
SET @@global.sort_buffer_size = 9000;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '9000'
SELECT @@sort_buffer_size = @@global.sort_buffer_size;
@@sort_buffer_size = @@global.sort_buffer_size
0
'#---------------------FN_DYNVARS_151_10----------------------#'
SET @@sort_buffer_size = 9000;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '9000'
SELECT @@sort_buffer_size = @@local.sort_buffer_size;
@@sort_buffer_size = @@local.sort_buffer_size
1
......@@ -169,14 +127,9 @@ SELECT @@local.sort_buffer_size = @@session.sort_buffer_size;
1
'#---------------------FN_DYNVARS_151_11----------------------#'
SET sort_buffer_size = 9100;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '9100'
SELECT @sort_buffer_size= 32776 OR @@sort_buffer_size= 32804;
@sort_buffer_size= 32776 OR @@sort_buffer_size= 32804
1
SELECT @@sort_buffer_size;
@@sort_buffer_size
32804
SELECT @@sort_buffer_size >= 32776 AND @@sort_buffer_size < 33000;
@@sort_buffer_size >= 32776 AND @@sort_buffer_size < 33000
1
SELECT local.sort_buffer_size;
ERROR 42S02: Unknown table 'local' in field list
SELECT session.sort_buffer_size;
......@@ -184,10 +137,4 @@ ERROR 42S02: Unknown table 'session' in field list
SELECT sort_buffer_size = @@session.sort_buffer_size;
ERROR 42S22: Unknown column 'sort_buffer_size' in 'field list'
SET @@global.sort_buffer_size = @start_global_value;
SELECT @@global.sort_buffer_size;
@@global.sort_buffer_size
262144
SET @@session.sort_buffer_size = @start_session_value;
SELECT @@session.sort_buffer_size;
@@session.sort_buffer_size
262144
SET @start_global_value = @@global.sort_buffer_size;
SELECT @start_global_value;
@start_global_value
262144
SET @start_session_value = @@session.sort_buffer_size;
SELECT @start_session_value;
@start_session_value
262144
'#--------------------FN_DYNVARS_151_01-------------------------#'
SET @@global.sort_buffer_size = 1000;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '1000'
SET @@global.sort_buffer_size = DEFAULT;
SELECT @@global.sort_buffer_size= 2097144 OR @@global.sort_buffer_size= 2097116;
@@global.sort_buffer_size= 2097144 OR @@global.sort_buffer_size= 2097116
SELECT @@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000;
@@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000
1
SET @@session.sort_buffer_size = 2000;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '2000'
SET @@session.sort_buffer_size = DEFAULT;
SELECT @@session.sort_buffer_size= 2097144 OR @@session.sort_buffer_size= 2097116;
@@session.sort_buffer_size= 2097144 OR @@session.sort_buffer_size= 2097116
SELECT @@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000;
@@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000
1
'#--------------------FN_DYNVARS_151_02-------------------------#'
SET @@global.sort_buffer_size = DEFAULT;
SELECT @@global.sort_buffer_size = 2097144 OR @@global.sort_buffer_size= 2097116;
@@global.sort_buffer_size = 2097144 OR @@global.sort_buffer_size= 2097116
SELECT @@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000;
@@global.sort_buffer_size >= 2097116 AND @@global.sort_buffer_size < 3000000
1
SET @@session.sort_buffer_size = DEFAULT;
SELECT @@session.sort_buffer_size = 2097144 OR @@session.sort_buffer_size= 2097116;
@@session.sort_buffer_size = 2097144 OR @@session.sort_buffer_size= 2097116
SELECT @@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000;
@@session.sort_buffer_size >= 2097116 AND @@session.sort_buffer_size < 3000000
1
'#--------------------FN_DYNVARS_151_03-------------------------#'
SET @@global.sort_buffer_size = 32776;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32776'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = 32777;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32777'
SELECT @@global.sort_buffer_size= 32777 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32777 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = 4294967295;
SELECT @@global.sort_buffer_size;
......@@ -51,19 +37,14 @@ SET @@global.sort_buffer_size = 4294967294;
SELECT @@global.sort_buffer_size;
@@global.sort_buffer_size
4294967294
'Bug# 34877: Invalid Values are showing in variable on assigning valid values.';
'#--------------------FN_DYNVARS_151_04-------------------------#'
SET @@session.sort_buffer_size = 32776;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32776'
SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804;
@@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
@@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000
1
SET @@session.sort_buffer_size = 32777;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32777'
SELECT @@session.sort_buffer_size= 32777 OR @@session.sort_buffer_size= 32804;
@@session.sort_buffer_size= 32777 OR @@session.sort_buffer_size= 32804
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
@@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000
1
SET @@session.sort_buffer_size = 4294967295;
SELECT @@session.sort_buffer_size;
......@@ -75,16 +56,12 @@ SELECT @@session.sort_buffer_size;
4294967294
'#------------------FN_DYNVARS_151_05-----------------------#'
SET @@global.sort_buffer_size = 32775;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32775'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = -1024;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '0'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = 4294967296;
SELECT @@global.sort_buffer_size;
......@@ -101,16 +78,12 @@ SELECT @@global.sort_buffer_size;
@@global.sort_buffer_size
4294967296
SET @@session.sort_buffer_size = 32775;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '32775'
SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804;
@@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
@@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000
1
SET @@session.sort_buffer_size = -2;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '0'
SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804;
@@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804
SELECT @@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000;
@@session.sort_buffer_size >= 32776 AND @@session.sort_buffer_size < 33000
1
SET @@session.sort_buffer_size = 65530.34.;
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '.' at line 1
......@@ -118,45 +91,34 @@ SET @@session.sort_buffer_size = 4294967296;
SELECT @@session.sort_buffer_size;
@@session.sort_buffer_size
4294967296
'Bug # 34837: Errors are not coming on assigning invalid values to variable';
SET @@session.sort_buffer_size = test;
ERROR 42000: Incorrect argument type to variable 'sort_buffer_size'
SELECT @@session.sort_buffer_size;
@@session.sort_buffer_size
4294967296
'#------------------FN_DYNVARS_151_06-----------------------#'
SELECT @@global.sort_buffer_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
SELECT @@global.sort_buffer_size = VARIABLE_VALUE FROM
INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
@@global.sort_buffer_size = VARIABLE_VALUE
1
'#------------------FN_DYNVARS_151_07-----------------------#'
SELECT @@session.sort_buffer_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
SELECT @@session.sort_buffer_size = VARIABLE_VALUE FROM
INFORMATION_SCHEMA.SESSION_VARIABLES WHERE VARIABLE_NAME='sort_buffer_size';
@@session.sort_buffer_size = VARIABLE_VALUE
1
'#------------------FN_DYNVARS_151_08-----------------------#'
SET @@global.sort_buffer_size = TRUE;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '1'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
SET @@global.sort_buffer_size = FALSE;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '0'
SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804;
@@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804
SELECT @@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000;
@@global.sort_buffer_size >= 32776 AND @@global.sort_buffer_size < 33000
1
'Bug: Errors should be displayed on assigning TRUE/FALSE to variable'
'#---------------------FN_DYNVARS_151_09----------------------#'
SET @@global.sort_buffer_size = 9000;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '9000'
SELECT @@sort_buffer_size = @@global.sort_buffer_size;
@@sort_buffer_size = @@global.sort_buffer_size
0
'#---------------------FN_DYNVARS_151_10----------------------#'
SET @@sort_buffer_size = 9000;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '9000'
SELECT @@sort_buffer_size = @@local.sort_buffer_size;
@@sort_buffer_size = @@local.sort_buffer_size
1
......@@ -165,14 +127,9 @@ SELECT @@local.sort_buffer_size = @@session.sort_buffer_size;
1
'#---------------------FN_DYNVARS_151_11----------------------#'
SET sort_buffer_size = 9100;
Warnings:
Warning 1292 Truncated incorrect sort_buffer_size value: '9100'
SELECT @sort_buffer_size= 32776 OR @@sort_buffer_size= 32804;
@sort_buffer_size= 32776 OR @@sort_buffer_size= 32804
1
SELECT @@sort_buffer_size;
@@sort_buffer_size
32804
SELECT @@sort_buffer_size >= 32776 AND @@sort_buffer_size < 33000;
@@sort_buffer_size >= 32776 AND @@sort_buffer_size < 33000
1
SELECT local.sort_buffer_size;
ERROR 42S02: Unknown table 'local' in field list
SELECT session.sort_buffer_size;
......@@ -180,10 +137,4 @@ ERROR 42S02: Unknown table 'session' in field list
SELECT sort_buffer_size = @@session.sort_buffer_size;
ERROR 42S22: Unknown column 'sort_buffer_size' in 'field list'
SET @@global.sort_buffer_size = @start_global_value;
SELECT @@global.sort_buffer_size;
@@global.sort_buffer_size
262144
SET @@session.sort_buffer_size = @start_session_value;
SELECT @@session.sort_buffer_size;
@@session.sort_buffer_size
262144
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