diff options
209 files changed, 20657 insertions, 5 deletions
diff --git a/.bzrignore b/.bzrignore index 16386496643..fbd2285ea78 100644 --- a/.bzrignore +++ b/.bzrignore @@ -3024,3 +3024,7 @@ win/vs8cache.txt ylwrap zlib/*.ds? zlib/*.vcproj +mysql-test/bug36522-64.tar +mysql-test/bug36522.tar +mysql-test/t.log +mysql-test/tps.log diff --git a/mysql-test/include/binlog_cache_size_basic.inc b/mysql-test/include/binlog_cache_size_basic.inc new file mode 100644 index 00000000000..323e19c4d66 --- /dev/null +++ b/mysql-test/include/binlog_cache_size_basic.inc @@ -0,0 +1,154 @@ +################# mysql-test\t\binlog_cache_size_basic.test #################### +# # +# Variable Name: binlog_cache_size # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 32768 # +# Range: 4096 - 4294967295 # +# # +# # +# Creation Date: 2008-04-28 # +# Author: Salman Rawala/Horst Hunger # +# # +# Description: Test Cases of Dynamic System Variable "binlog_cache_size" # +# that checks behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity . # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html#option_mysqld_binlog_cache_size # +# # +################################################################################ + +################################################################# +# START OF binlog_cache_size TESTS # +################################################################# + +######################################################################### +# Saving initial value of binlog_cache_size in a temporary variable # +######################################################################### + +SET @start_value = @@global.binlog_cache_size; +SELECT @start_value; + +--echo '#--------------------FN_DYNVARS_006_01------------------------#' +######################################################################### +# Display the DEFAULT value of binlog_cache_size # +######################################################################### + +SET @@global.binlog_cache_size = 100; +SET @@global.binlog_cache_size = DEFAULT; +SELECT @@global.binlog_cache_size; + + +--echo '#---------------------FN_DYNVARS_006_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.binlog_cache_size = @start_value; +SELECT @@global.binlog_cache_size = 32768; + + +--echo '#--------------------FN_DYNVARS_006_03------------------------#' +######################################################################### +# Change the value of binlog_cache_size to a valid value # +######################################################################### + +SET @@global.binlog_cache_size = 4096; +SELECT @@global.binlog_cache_size; +SET @@global.binlog_cache_size = 4294967295; +SELECT @@global.binlog_cache_size; +SET @@global.binlog_cache_size = 10000; +SELECT @@global.binlog_cache_size; +SET @@global.binlog_cache_size = 21221204; +SELECT @@global.binlog_cache_size; +echo 'Bug: Invalid values are coming in variable on assigning valid values'; + + +--echo '#--------------------FN_DYNVARS_006_04-------------------------#' +############################################################################ +# Change the value of binlog_cache_size to invalid value # +############################################################################ + +SET @@global.binlog_cache_size = 1024; +SELECT @@global.binlog_cache_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.binlog_cache_size = 10000.01; +SET @@global.binlog_cache_size = -1024; +SELECT @@global.binlog_cache_size; +SET @@global.binlog_cache_size = 42949672950; +SELECT @@global.binlog_cache_size; +echo 'Bug: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.binlog_cache_size = ON; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.binlog_cache_size = 'test'; + + +--echo '#-------------------FN_DYNVARS_006_05----------------------------#' +############################################################################ +# Test if accessing session binlog_cache_size gives error # +############################################################################ + +--Error ER_GLOBAL_VARIABLE +SET @@session.binlog_cache_size = 0; + + +--echo '#----------------------FN_DYNVARS_006_06------------------------#' +############################################################################## +# Check if the value in GLOBAL Tables matches values in variable # +############################################################################## + +SELECT @@global.binlog_cache_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='binlog_cache_size'; + +--echo '#---------------------FN_DYNVARS_006_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.binlog_cache_size = TRUE; +SELECT @@global.binlog_cache_size; +SET @@global.binlog_cache_size = FALSE; +SELECT @@global.binlog_cache_size; +echo 'Bug: Errors are not coming on assigning TRUE/FALSE to variable'; + +--echo '#---------------------FN_DYNVARS_006_08----------------------#' +############################################################################### +# Check if accessing variable without SCOPE points to same global variable # +############################################################################### + +SET @@global.binlog_cache_size = 1; +SELECT @@binlog_cache_size = @@global.binlog_cache_size; + +--echo '#---------------------FN_DYNVARS_006_09----------------------#' +########################################################################### +# Check if binlog_cache_size can be accessed with and without @@ sign # +########################################################################### + +--Error ER_GLOBAL_VARIABLE +SET binlog_cache_size = 1; +--Error ER_PARSE_ERROR +SET global.binlog_cache_size = 1; +--Error ER_UNKNOWN_TABLE +SELECT global.binlog_cache_size; +--Error ER_BAD_FIELD_ERROR +SELECT binlog_cache_size = @@session.binlog_cache_size; + + +############################## +# Restore initial value # +############################## + +SET @@global.binlog_cache_size = @start_value; +SELECT @@global.binlog_cache_size; + + +########################################################### +# END OF binlog_cache_size TESTS # +########################################################### diff --git a/mysql-test/include/bulk_insert_buffer_size_basic.inc b/mysql-test/include/bulk_insert_buffer_size_basic.inc new file mode 100644 index 00000000000..56ffbace173 --- /dev/null +++ b/mysql-test/include/bulk_insert_buffer_size_basic.inc @@ -0,0 +1,203 @@ +############## mysql-test\t\bulk_insert_buffer_size_basic.test ################# +# # +# Variable Name: bulk_insert_buffer_size # +# Scope: GLOBAL & SESSION # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 8388608 # +# Range: 0 - 4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman Rawala # +# # +# Description: Test Cases of Dynamic System Variable "bulk_insert_buffer_size" # +# that checks behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity . # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html#option_mysqld_bulk_insert_buffer_size # +# # +################################################################################ + +--source include/load_sysvars.inc + +####################################################################### +# START OF bulk_insert_buffer_size TESTS # +####################################################################### + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.bulk_insert_buffer_size; +SELECT @start_global_value; +SET @start_session_value = @@session.bulk_insert_buffer_size; +SELECT @start_session_value; + +--echo '#--------------------FN_DYNVARS_007_01-------------------------#' +####################################################################### +# Display the DEFAULT value of bulk_insert_buffer_size # +####################################################################### + +SET @@global.bulk_insert_buffer_size = 100; +SET @@global.bulk_insert_buffer_size = DEFAULT; +SELECT @@global.bulk_insert_buffer_size; + +SET @@session.bulk_insert_buffer_size = 200; +SET @@session.bulk_insert_buffer_size = DEFAULT; +SELECT @@session.bulk_insert_buffer_size; + + +--echo '#--------------------FN_DYNVARS_007_02-------------------------#' +####################################################################### +# Check the DEFAULT value of bulk_insert_buffer_size # +####################################################################### + +SET @@global.bulk_insert_buffer_size = @start_global_value; +SELECT @@global.bulk_insert_buffer_size = 8388608; + +SET @@session.bulk_insert_buffer_size = @start_session_value; +SELECT @@session.bulk_insert_buffer_size = 8388608; + + +--echo '#--------------------FN_DYNVARS_007_03-------------------------#' +############################################################################### +#Change the value of bulk_insert_buffer_size to valid values for GLOBAL Scope # +############################################################################### + +SET @@global.bulk_insert_buffer_size = 0; +SELECT @@global.bulk_insert_buffer_size; +SET @@global.bulk_insert_buffer_size = 1; +SELECT @@global.bulk_insert_buffer_size; +SET @@global.bulk_insert_buffer_size = 4294967295; +SELECT @@global.bulk_insert_buffer_size; +SET @@global.bulk_insert_buffer_size = 429496; +SELECT @@global.bulk_insert_buffer_size; + + +--echo '#--------------------FN_DYNVARS_007_04-------------------------#' +############################################################################### +#Change the value of bulk_insert_buffer_size to valid values for SESSION Scope# +############################################################################### + +SET @@session.bulk_insert_buffer_size = 0; +SELECT @@session.bulk_insert_buffer_size; +SET @@session.bulk_insert_buffer_size = 1; +SELECT @@session.bulk_insert_buffer_size; +SET @@session.bulk_insert_buffer_size = 4294967295; +SELECT @@session.bulk_insert_buffer_size; +SET @@session.bulk_insert_buffer_size = 429496; +SELECT @@session.bulk_insert_buffer_size; + + +--echo '#------------------FN_DYNVARS_007_05-----------------------#' +################################################################### +# Change the value of bulk_insert_buffer_size to an invalid value # +################################################################### + +SET @@global.bulk_insert_buffer_size = 42949672950; +SELECT @@global.bulk_insert_buffer_size; +SET @@global.bulk_insert_buffer_size = -1024; +SELECT @@global.bulk_insert_buffer_size; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.bulk_insert_buffer_size = test; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.bulk_insert_buffer_size = ON; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.bulk_insert_buffer_size = 429496.10; + +SET @@session.bulk_insert_buffer_size = 42949672950; +SELECT @@session.bulk_insert_buffer_size; +SET @@session.bulk_insert_buffer_size = -2; +SELECT @@session.bulk_insert_buffer_size; +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.bulk_insert_buffer_size = test; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.bulk_insert_buffer_size = 429496.10; + + +--echo '#------------------FN_DYNVARS_007_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + +SELECT @@global.bulk_insert_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='bulk_insert_buffer_size'; + +--echo '#------------------FN_DYNVARS_007_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.bulk_insert_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='bulk_insert_buffer_size'; + + +--echo '#------------------FN_DYNVARS_007_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.bulk_insert_buffer_size = TRUE; +SELECT @@global.bulk_insert_buffer_size; +SET @@global.bulk_insert_buffer_size = FALSE; +SELECT @@global.bulk_insert_buffer_size; + +SET @@session.bulk_insert_buffer_size = TRUE; +SELECT @@session.bulk_insert_buffer_size; +SET @@session.bulk_insert_buffer_size = FALSE; +SELECT @@session.bulk_insert_buffer_size; + + +--echo '#---------------------FN_DYNVARS_007_09----------------------#' +############################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points # +# to same session variable # +############################################################################## + +SET @@bulk_insert_buffer_size = 100; +SELECT @@bulk_insert_buffer_size = @@local.bulk_insert_buffer_size; +SELECT @@local.bulk_insert_buffer_size = @@session.bulk_insert_buffer_size; + + +--echo '#---------------------FN_DYNVARS_007_10----------------------#' +############################################################################### +# Check if bulk_insert_buffer_size can be accessed with and without @@ sign # +############################################################################### + +SET bulk_insert_buffer_size = 1; +SELECT @@bulk_insert_buffer_size; +--Error ER_PARSE_ERROR +SET local.bulk_insert_buffer_size = 1; +--Error ER_UNKNOWN_TABLE +SELECT local.bulk_insert_buffer_size; +--Error ER_PARSE_ERROR +SET session.bulk_insert_buffer_size = 1; +--Error ER_UNKNOWN_TABLE +SELECT session.bulk_insert_buffer_size; +--Error ER_BAD_FIELD_ERROR +SELECT bulk_insert_buffer_size = @@session.bulk_insert_buffer_size; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.bulk_insert_buffer_size = @start_global_value; +SELECT @@global.bulk_insert_buffer_size; +SET @@session.bulk_insert_buffer_size = @start_session_value; +SELECT @@session.bulk_insert_buffer_size; + + +#################################################### +# END OF bulk_insert_buffer_size TESTS # +#################################################### diff --git a/mysql-test/include/delayed_insert_limit_basic.inc b/mysql-test/include/delayed_insert_limit_basic.inc new file mode 100644 index 00000000000..ab158bc593e --- /dev/null +++ b/mysql-test/include/delayed_insert_limit_basic.inc @@ -0,0 +1,167 @@ +############### mysql-test\t\delayed_insert_limit_basic.test ################### +# # +# Variable Name: delayed_insert_limit # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 100 # +# Range: 1 - 4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman Rawala # +# # +# Description: Test Cases of Dynamic System Variable "delayed_insert_limit" # +# that checks behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html#option_mysqld_delayed_insert_limit # +# # +################################################################################ + +--source include/load_sysvars.inc + +################################################################# +# START OF delayed_insert_limit TESTS # +################################################################# + +######################################################################### +# Saving initial value of delayed_insert_limit in a temporary variable # +######################################################################### + +SET @start_value = @@global.delayed_insert_limit; +SELECT @start_value; + +--echo '#--------------------FN_DYNVARS_024_01------------------------#' +######################################################################### +# Display the DEFAULT value of delayed_insert_limit # +######################################################################### + +SET @@global.delayed_insert_limit = 100; +SET @@global.delayed_insert_limit = DEFAULT; +SELECT @@global.delayed_insert_limit; + + +--echo '#---------------------FN_DYNVARS_024_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.delayed_insert_limit = @start_value; +SELECT @@global.delayed_insert_limit = 100; + + +--echo '#--------------------FN_DYNVARS_024_03------------------------#' +######################################################################### +# Change the value of delayed_insert_limit to a valid value # +######################################################################### + +SET @@global.delayed_insert_limit = 10000; +SELECT @@global.delayed_insert_limit; +SET @@global.delayed_insert_limit = 4294967295; +SELECT @@global.delayed_insert_limit; +SET @@global.delayed_insert_limit = 1; +SELECT @@global.delayed_insert_limit; + + +--echo '#--------------------FN_DYNVARS_024_04-------------------------#' +############################################################################ +# Change the value of delayed_insert_limit to invalid value # +############################################################################ + +SET @@global.delayed_insert_limit = 0; +SELECT @@global.delayed_insert_limit; +SET @@global.delayed_insert_limit = -1024; +SELECT @@global.delayed_insert_limit; +SET @@global.delayed_insert_limit = 42949672950; +SELECT @@global.delayed_insert_limit; +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.delayed_insert_limit = 429496729.5; +SELECT @@global.delayed_insert_limit; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.delayed_insert_limit = ON; +SELECT @@global.delayed_insert_limit; + + + +--echo '#-------------------FN_DYNVARS_024_05----------------------------#' +############################################################################ +# Test if accessing session delayed_insert_limit gives error # +############################################################################ + +--Error ER_GLOBAL_VARIABLE +SET @@session.delayed_insert_limit = 0; +--Error ER_INCORRECT_GLOBAL_LOCAL_VAR +SELECT @@Session.delayed_insert_limit; + + +--echo '#----------------------FN_DYNVARS_024_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.delayed_insert_limit = + VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES + WHERE VARIABLE_NAME='delayed_insert_limit'; + +SELECT @@delayed_insert_limit = + VARIABLE_VALUE FROM INFORMATION_SCHEMA.SESSION_VARIABLES + WHERE VARIABLE_NAME='delayed_insert_limit'; + + +--echo '#---------------------FN_DYNVARS_024_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.delayed_insert_limit = TRUE; +SELECT @@global.delayed_insert_limit; +SET @@global.delayed_insert_limit = FALSE; +SELECT @@global.delayed_insert_limit; + +--echo '#---------------------FN_DYNVARS_024_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.delayed_insert_limit = 1; +SELECT @@delayed_insert_limit = @@global.delayed_insert_limit; + + +--echo '#---------------------FN_DYNVARS_024_09----------------------#' +############################################################################## +# Check if delayed_insert_limit can be accessed with and without @@ sign # +############################################################################## + +--Error ER_GLOBAL_VARIABLE +SET delayed_insert_limit = 1; +SELECT @@delayed_insert_limit; +--Error ER_PARSE_ERROR +SET local.delayed_insert_limit = 1; +--Error ER_UNKNOWN_TABLE +SELECT local.delayed_insert_limit; +--Error ER_PARSE_ERROR +SET global.delayed_insert_limit = 1; +--Error ER_UNKNOWN_TABLE +SELECT global.delayed_insert_limit; +--Error ER_BAD_FIELD_ERROR +SELECT delayed_insert_limit = @@session.delayed_insert_limit; + +############################## +# Restore initial value # +############################## + +SET @@global.delayed_insert_limit = @start_value; +SELECT @@global.delayed_insert_limit; + + +########################################################### +# END OF delayed_insert_limit TESTS # +########################################################### + diff --git a/mysql-test/include/delayed_queue_size_basic.inc b/mysql-test/include/delayed_queue_size_basic.inc new file mode 100644 index 00000000000..2d16f75d4e1 --- /dev/null +++ b/mysql-test/include/delayed_queue_size_basic.inc @@ -0,0 +1,163 @@ +################# mysql-test\t\delayed_queue_size_basic.test ################### +# # +# Variable Name: delayed_queue_size # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 1000 # +# Range: 1 - 4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman Rawala # +# # +# Description: Test Cases of Dynamic System Variable "delayed_queue_size" # +# that checks behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity . # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html#option_mysqld_delayed_queue_size # +# # +################################################################################ + +--source include/load_sysvars.inc + +################################################################# +# START OF delayed_queue_size TESTS # +################################################################# + +######################################################################### +# Saving initial value of delayed_queue_size in a temporary variable # +######################################################################### + +SET @start_value = @@global.delayed_queue_size; +SELECT @start_value; + +--echo '#--------------------FN_DYNVARS_026_01------------------------#' +######################################################################### +# Display the DEFAULT value of delayed_queue_size # +######################################################################### + +SET @@global.delayed_queue_size = 100; +SET @@global.delayed_queue_size = DEFAULT; +SELECT @@global.delayed_queue_size; + +--echo '#---------------------FN_DYNVARS_026_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.delayed_queue_size = @start_value; +SELECT @@global.delayed_queue_size = 1000; + +--echo '#--------------------FN_DYNVARS_026_03------------------------#' +######################################################################### +# Change the value of delayed_queue_size to a valid value # +######################################################################### + +SET @@global.delayed_queue_size = 10000; +SELECT @@global.delayed_queue_size; +SET @@global.delayed_queue_size = 4294967295; +SELECT @@global.delayed_queue_size; +SET @@global.delayed_queue_size = 1; +SELECT @@global.delayed_queue_size; + + +--echo '#--------------------FN_DYNVARS_026_04-------------------------#' +############################################################################ +# Change the value of delayed_queue_size to invalid value # +############################################################################ + +SET @@global.delayed_queue_size = 0; +SELECT @@global.delayed_queue_size; +SET @@global.delayed_queue_size = -1024; +SELECT @@global.delayed_queue_size; +SET @@global.delayed_queue_size = 42949672950; +SELECT @@global.delayed_queue_size; +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.delayed_queue_size = 429496729.5; +SELECT @@global.delayed_queue_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.delayed_queue_size = ON; +SELECT @@delayed_queue_size; + +--echo '#-------------------FN_DYNVARS_026_05----------------------------#' +############################################################################ +# Test if accessing session delayed_queue_size gives error # +############################################################################ + +--Error 1229 +SET @@session.delayed_queue_size = 0; +--Error 1238 +SELECT @@session.delayed_queue_size; + +--echo '#----------------------FN_DYNVARS_026_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.delayed_queue_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='delayed_queue_size'; + +SELECT @@delayed_queue_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='delayed_queue_size'; + + +--echo '#---------------------FN_DYNVARS_026_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.delayed_queue_size = TRUE; +SELECT @@global.delayed_queue_size; +SET @@global.delayed_queue_size = FALSE; +SELECT @@global.delayed_queue_size; + +--echo '#---------------------FN_DYNVARS_026_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.delayed_queue_size = 1; +SELECT @@delayed_queue_size = @@global.delayed_queue_size; + + +--echo '#---------------------FN_DYNVARS_026_09----------------------#' +########################################################################### +# Check if delayed_queue_size can be accessed with and without @@ sign # +########################################################################### + +--Error 1229 +SET delayed_queue_size = 1; +SELECT @@delayed_queue_size; +--Error ER_PARSE_ERROR +SET local.delayed_queue_size = 1; +--Error ER_UNKNOWN_TABLE +SELECT local.delayed_queue_size; +--Error ER_PARSE_ERROR +SET global.delayed_queue_size = 1; +--Error ER_UNKNOWN_TABLE +SELECT global.delayed_queue_size; +--Error ER_BAD_FIELD_ERROR +SELECT delayed_queue_size = @@session.delayed_queue_size; + + +############################## +# Restore initial value # +############################## + +SET @@global.delayed_queue_size = @start_value; +SELECT @@global.delayed_queue_size; + + +########################################################### +# END OF delayed_queue_size TESTS # +########################################################### + diff --git a/mysql-test/include/have_32bit.inc b/mysql-test/include/have_32bit.inc new file mode 100644 index 00000000000..b09a813967d --- /dev/null +++ b/mysql-test/include/have_32bit.inc @@ -0,0 +1,16 @@ +# Created by Horst Hunger 2008-04-15 +# see also have_64bit.inc + +--disable_query_log +--disable_warnings +let $save = `SELECT @@global.sort_buffer_size`; +SET @@global.sort_buffer_size = 4294967296; +let $mach32 = `SELECT @@global.sort_buffer_size <= 4294967295`; +eval SET @@global.sort_buffer_size = $save; +--enable_warnings +--enable_query_log +if (!$mach32) +{ + skip Need a 32 bit machine; +} + diff --git a/mysql-test/include/have_64bit.inc b/mysql-test/include/have_64bit.inc new file mode 100644 index 00000000000..31529a0c9d4 --- /dev/null +++ b/mysql-test/include/have_64bit.inc @@ -0,0 +1,14 @@ +# Created by Horst Hunger 2008-04-15 +# see also have_32bit.inc + +--disable_query_log +let $save = `SELECT @@session.sort_buffer_size`; +SET @@session.sort_buffer_size = 4294967296; +let $mach64 = `SELECT @@session.sort_buffer_size > 4294967295`; +eval SET @@session.sort_buffer_size = $save; +--enable_query_log +if (!$mach64) +{ + skip Need a 64 bit machine; +} + diff --git a/mysql-test/include/innodb_concurrency_tickets_basic.inc b/mysql-test/include/innodb_concurrency_tickets_basic.inc new file mode 100644 index 00000000000..67b0247d169 --- /dev/null +++ b/mysql-test/include/innodb_concurrency_tickets_basic.inc @@ -0,0 +1,147 @@ +################# mysql-test\t\innodb_concurrency_tickets_basic.test ########## +# # +# Variable Name: innodb_concurrency_tickets # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 500 # +# Range: 1-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan # +# # +#Description:Test Cases of Dynamic System Variable innodb_concurrency_tickets # +# that checks the behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/have_innodb.inc +--source include/load_sysvars.inc + +######################################################################## +# START OF innodb_concurrency_tickets TESTS # +######################################################################## + + +################################################################################ +# Saving initial value of innodb_concurrency_tickets in a temporary variable # +################################################################################ + +SET @global_start_value = @@global.innodb_concurrency_tickets; +SELECT @global_start_value; + +--echo '#--------------------FN_DYNVARS_046_01------------------------#' +######################################################################## +# Display the DEFAULT value of innodb_concurrency_tickets # +######################################################################## + +SET @@global.innodb_concurrency_tickets = 0; +SET @@global.innodb_concurrency_tickets = DEFAULT; +SELECT @@global.innodb_concurrency_tickets; + +--echo '#---------------------FN_DYNVARS_046_02-------------------------#' +################################################################################ +# Check if innodb_concurrency_tickets can be accessed with and without @@ sign # +################################################################################ + +--Error ER_GLOBAL_VARIABLE +SET innodb_concurrency_tickets = 1; +SELECT @@innodb_concurrency_tickets; + +--Error ER_UNKNOWN_TABLE +SELECT local.innodb_concurrency_tickets; + + +SET global innodb_concurrency_tickets = 0; +SELECT @@global.innodb_concurrency_tickets; + + +--echo '#--------------------FN_DYNVARS_046_03------------------------#' +########################################################################## +# change the value of innodb_concurrency_tickets to a valid value # +########################################################################## + + +SET @@global.innodb_concurrency_tickets = 1; +SELECT @@global.innodb_concurrency_tickets; + +SET @@global.innodb_concurrency_tickets = 1000; +SELECT @@global.innodb_concurrency_tickets; + +SET @@global.innodb_concurrency_tickets = 4294967295; +SELECT @@global.innodb_concurrency_tickets; + + +--echo '#--------------------FN_DYNVARS_046_04-------------------------#' +########################################################################### +# Change the value of innodb_concurrency_tickets to invalid value # +########################################################################### + +SET @@global.innodb_concurrency_tickets = -1; +SELECT @@global.innodb_concurrency_tickets; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_concurrency_tickets = "T"; +SELECT @@global.innodb_concurrency_tickets; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_concurrency_tickets = "Y"; +SELECT @@global.innodb_concurrency_tickets; + +SET @@global.innodb_concurrency_tickets = 1001; +SELECT @@global.innodb_concurrency_tickets; + +--echo '#----------------------FN_DYNVARS_046_05------------------------#' +######################################################################### +# Check if the value in GLOBAL Table matches value in variable # +######################################################################### + +SELECT @@global.innodb_concurrency_tickets = + VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES + WHERE VARIABLE_NAME='innodb_concurrency_tickets'; +SELECT @@global.innodb_concurrency_tickets; +SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES + WHERE VARIABLE_NAME='innodb_concurrency_tickets'; + +--echo '#---------------------FN_DYNVARS_046_06-------------------------#' +################################################################### +# Check if ON and OFF values can be used on variable # +################################################################### + +--ERROR ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_concurrency_tickets = OFF; +SELECT @@global.innodb_concurrency_tickets; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_concurrency_tickets = ON; +SELECT @@global.innodb_concurrency_tickets; + +--echo '#---------------------FN_DYNVARS_046_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.innodb_concurrency_tickets = TRUE; +SELECT @@global.innodb_concurrency_tickets; +SET @@global.innodb_concurrency_tickets = FALSE; +SELECT @@global.innodb_concurrency_tickets; + +############################## +# Restore initial value # +############################## + +SET @@global.innodb_concurrency_tickets = @global_start_value; +SELECT @@global.innodb_concurrency_tickets; + +############################################################### +# END OF innodb_concurrency_tickets TESTS # +############################################################### + diff --git a/mysql-test/include/innodb_max_purge_lag_basic.inc b/mysql-test/include/innodb_max_purge_lag_basic.inc new file mode 100644 index 00000000000..9e6b8201e3d --- /dev/null +++ b/mysql-test/include/innodb_max_purge_lag_basic.inc @@ -0,0 +1,147 @@ +################# mysql-test\t\innodb_max_purge_lag_basic.test ################ +# # +# Variable Name: innodb_max_purge_lag # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 0 # +# Range: 0-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan # +# # +#Description:Test Cases of Dynamic System Variable innodb_max_purge_lag # +# that checks the behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/have_innodb.inc +--source include/load_sysvars.inc + +######################################################################## +# START OF innodb_max_purge_lag TESTS # +######################################################################## + +################################################################################ +# Saving initial value of innodb_max_purge_lag in a temporary variable # +################################################################################ + +SET @global_start_value = @@global.innodb_max_purge_lag; +SELECT @global_start_value; + +--echo '#--------------------FN_DYNVARS_046_01------------------------#' +######################################################################## +# Display the DEFAULT value of innodb_max_purge_lag # +######################################################################## + +SET @@global.innodb_max_purge_lag = 0; +SET @@global.innodb_max_purge_lag = DEFAULT; +SELECT @@global.innodb_max_purge_lag; + +--echo '#---------------------FN_DYNVARS_046_02-------------------------#' +############################################################################ +# Check if innodb_max_purge_lag can be accessed with and without @@ sign # +############################################################################ + +--Error ER_GLOBAL_VARIABLE +SET innodb_max_purge_lag = 1; +SELECT @@innodb_max_purge_lag; + +--Error ER_UNKNOWN_TABLE +SELECT local.innodb_max_purge_lag; + +SET global innodb_max_purge_lag = 0; +SELECT @@global.innodb_max_purge_lag; + +--echo '#--------------------FN_DYNVARS_046_03------------------------#' +########################################################################## +# change the value of innodb_max_purge_lag to a valid value # +########################################################################## + + +SET @@global.innodb_max_purge_lag = 0; +SELECT @@global.innodb_max_purge_lag; + +SET @@global.innodb_max_purge_lag = 1; +SELECT @@global.innodb_max_purge_lag; +SET @@global.innodb_max_purge_lag = 4294967295; +SELECT @@global.innodb_max_purge_lag; + +--echo '#--------------------FN_DYNVARS_046_04-------------------------#' +########################################################################### +# Change the value of innodb_max_purge_lag to invalid value # +########################################################################### + +SET @@global.innodb_max_purge_lag = -1; +SELECT @@global.innodb_max_purge_lag; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_max_purge_lag = "T"; +SELECT @@global.innodb_max_purge_lag; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_max_purge_lag = "Y"; +SELECT @@global.innodb_max_purge_lag; + + +SET @@global.innodb_max_purge_lag = 1001; +SELECT @@global.innodb_max_purge_lag; + +--echo '#----------------------FN_DYNVARS_046_05------------------------#' +######################################################################### +# Check if the value in GLOBAL Table matches value in variable # +######################################################################### + +SELECT @@global.innodb_max_purge_lag = + VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES + WHERE VARIABLE_NAME='innodb_max_purge_lag'; +SELECT @@global.innodb_max_purge_lag; +SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES + WHERE VARIABLE_NAME='innodb_max_purge_lag'; + + + + +--echo '#---------------------FN_DYNVARS_046_06-------------------------#' +################################################################### +# Check if ON and OFF values can be used on variable # +################################################################### + +--ERROR ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_max_purge_lag = OFF; +SELECT @@global.innodb_max_purge_lag; + +--ERROR ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_max_purge_lag = ON; +SELECT @@global.innodb_max_purge_lag; + +--echo '#---------------------FN_DYNVARS_046_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + + +SET @@global.innodb_max_purge_lag = TRUE; +SELECT @@global.innodb_max_purge_lag; +SET @@global.innodb_max_purge_lag = FALSE; +SELECT @@global.innodb_max_purge_lag; + +############################## +# Restore initial value # +############################## + + +SET @@global.innodb_max_purge_lag = @global_start_value; +SELECT @@global.innodb_max_purge_lag; + +############################################################### +# END OF innodb_max_purge_lag TESTS # +############################################################### diff --git a/mysql-test/include/innodb_sync_spin_loops_basic.inc b/mysql-test/include/innodb_sync_spin_loops_basic.inc new file mode 100644 index 00000000000..35460fe47f2 --- /dev/null +++ b/mysql-test/include/innodb_sync_spin_loops_basic.inc @@ -0,0 +1,142 @@ +################# mysql-test\t\innodb_sync_spin_loops_basic.test ############## +# # +# Variable Name: innodb_sync_spin_loops # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 20 # +# Range: 0-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan # +# # +#Description:Test Cases of Dynamic System Variable innodb_sync_spin_loops # +# that checks the behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/have_innodb.inc +--source include/load_sysvars.inc + +######################################################################## +# START OF innodb_sync_spin_loops TESTS # +######################################################################## + + +############################################################################ +# Saving initial value of innodb_sync_spin_loops in a temporary variable # +############################################################################ + +SET @global_start_value = @@global.innodb_sync_spin_loops; +SELECT @global_start_value; + +--echo '#--------------------FN_DYNVARS_046_01------------------------#' +######################################################################## +# Display the DEFAULT value of innodb_sync_spin_loops # +######################################################################## + +SET @@global.innodb_sync_spin_loops = 0; +SET @@global.innodb_sync_spin_loops = DEFAULT; +SELECT @@global.innodb_sync_spin_loops; + +--echo '#---------------------FN_DYNVARS_046_02-------------------------#' +############################################################################## +# Check if innodb_sync_spin_loops can be accessed with and without @@ sign # +############################################################################## + +--Error ER_GLOBAL_VARIABLE +SET innodb_sync_spin_loops = 1; +SELECT @@innodb_sync_spin_loops; + +--Error ER_UNKNOWN_TABLE +SELECT local.innodb_sync_spin_loops; + +SET global innodb_sync_spin_loops = 0; +SELECT @@global.innodb_sync_spin_loops; + +--echo '#--------------------FN_DYNVARS_046_03------------------------#' +########################################################################## +# change the value of innodb_sync_spin_loops to a valid value # +########################################################################## + +SET @@global.innodb_sync_spin_loops = 0; +SELECT @@global.innodb_sync_spin_loops; + +SET @@global.innodb_sync_spin_loops = 1; +SELECT @@global.innodb_sync_spin_loops; +SET @@global.innodb_sync_spin_loops = 1000; +SELECT @@global.innodb_sync_spin_loops; + +--echo '#--------------------FN_DYNVARS_046_04-------------------------#' +########################################################################### +# Change the value of innodb_sync_spin_loops to invalid value # +########################################################################### + +SET @@global.innodb_sync_spin_loops = -1; +SELECT @@global.innodb_sync_spin_loops; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_sync_spin_loops = "T"; +SELECT @@global.innodb_sync_spin_loops; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_sync_spin_loops = "Y"; +SELECT @@global.innodb_sync_spin_loops; + +SET @@global.innodb_sync_spin_loops = 1001; +SELECT @@global.innodb_sync_spin_loops; + +--echo '#----------------------FN_DYNVARS_046_05------------------------#' +######################################################################### +# Check if the value in GLOBAL Table matches value in variable # +######################################################################### + +SELECT @@global.innodb_sync_spin_loops = + VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES + WHERE VARIABLE_NAME='innodb_sync_spin_loops'; +SELECT @@global.innodb_sync_spin_loops; +SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES + WHERE VARIABLE_NAME='innodb_sync_spin_loops'; + +--echo '#---------------------FN_DYNVARS_046_06-------------------------#' +################################################################### +# Check if ON and OFF values can be used on variable # +################################################################### + +--ERROR ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_sync_spin_loops = OFF; +SELECT @@global.innodb_sync_spin_loops; + +--ERROR ER_WRONG_TYPE_FOR_VAR +SET @@global.innodb_sync_spin_loops = ON; +SELECT @@global.innodb_sync_spin_loops; + +--echo '#---------------------FN_DYNVARS_046_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + + +SET @@global.innodb_sync_spin_loops = TRUE; +SELECT @@global.innodb_sync_spin_loops; +SET @@global.innodb_sync_spin_loops = FALSE; +SELECT @@global.innodb_sync_spin_loops; + +############################## +# Restore initial value # +############################## + +SET @@global.innodb_sync_spin_loops = @global_start_value; +SELECT @@global.innodb_sync_spin_loops; + +############################################################### +# END OF innodb_sync_spin_loops TESTS # +############################################################### diff --git a/mysql-test/include/join_buffer_size_basic.inc b/mysql-test/include/join_buffer_size_basic.inc new file mode 100644 index 00000000000..880dac4cac4 --- /dev/null +++ b/mysql-test/include/join_buffer_size_basic.inc @@ -0,0 +1,216 @@ +############## mysql-test\t\join_buffer_size_basic.test ############### +# # +# Variable Name: join_buffer_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 131072 # +# Range: 8200-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable join_buffer_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +################################################################ +# START OF join_buffer_size TESTS # +################################################################ + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.join_buffer_size; +SELECT @start_global_value; +SET @start_session_value = @@session.join_buffer_size; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_053_01-------------------------#' +################################################################ +# Display the DEFAULT value of join_buffer_size # +################################################################ + +SET @@global.join_buffer_size = 8200; +SET @@global.join_buffer_size = DEFAULT; +SELECT @@global.join_buffer_size; + +SET @@session.join_buffer_size = 8200; +SET @@session.join_buffer_size = DEFAULT; +SELECT @@session.join_buffer_size; + + +--echo '#--------------------FN_DYNVARS_053_02-------------------------#' +################################################################### +# Check the DEFAULT value of join_buffer_size # +################################################################### + +SET @@global.join_buffer_size = DEFAULT; +SELECT @@global.join_buffer_size = 131072; + +SET @@session.join_buffer_size = DEFAULT; +SELECT @@session.join_buffer_size = 131072; + + +--echo '#--------------------FN_DYNVARS_053_03-------------------------#' +########################################################################## +# Change the value of join_buffer_size to a valid value for GLOBAL Scope # +########################################################################## + +SET @@global.join_buffer_size = 8200; +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +SET @@global.join_buffer_size = 65536; +SELECT @@global.join_buffer_size; +SET @@global.join_buffer_size = 4294967295; +SELECT @@global.join_buffer_size; +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + + +--echo '#--------------------FN_DYNVARS_053_04-------------------------#' +########################################################################### +# Change the value of join_buffer_size to a valid value for SESSION Scope # +########################################################################### + +SET @@session.join_buffer_size = 8200; +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +SET @@session.join_buffer_size = 65536; +SELECT @@session.join_buffer_size; +SET @@session.join_buffer_size = 4294967295; +SELECT @@session.join_buffer_size; +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + + +--echo '#------------------FN_DYNVARS_053_05-----------------------#' +############################################################ +# Change the value of join_buffer_size to an invalid value # +############################################################ + +SET @@global.join_buffer_size = 0; +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +SET @@global.join_buffer_size = -1024; +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +SET @@global.join_buffer_size = 8199; +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +SET @@global.join_buffer_size = 42949672951; +SELECT @@global.join_buffer_size; + +--Error ER_PARSE_ERROR +SET @@global.join_buffer_size = 65530.34.; +SELECT @@global.join_buffer_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.join_buffer_size = test; +SELECT @@global.join_buffer_size; + +SET @@session.join_buffer_size = 0; +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +SET @@session.join_buffer_size = -2; +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +SET @@session.join_buffer_size = 8199; +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +SET @@session.join_buffer_size = 42949672951; +SELECT @@session.join_buffer_size; + +--Error ER_PARSE_ERROR +SET @@session.join_buffer_size = 65530.34.; +SELECT @@session.join_buffer_size; +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.join_buffer_size = test; +SELECT @@session.join_buffer_size; + + +--echo '#------------------FN_DYNVARS_053_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.join_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='join_buffer_size'; + +--echo '#------------------FN_DYNVARS_053_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.join_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='join_buffer_size'; + + +--echo '#------------------FN_DYNVARS_053_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.join_buffer_size = TRUE; +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +SET @@global.join_buffer_size = FALSE; +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +--echo 'Bug: Errors are not coming on assigning TRUE/FALSE to variable'; + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + +SET @@global.join_buffer_size = 10; +SELECT @@join_buffer_size = @@global.join_buffer_size; + + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@join_buffer_size = 100; +SELECT @@join_buffer_size = @@local.join_buffer_size; +SELECT @@local.join_buffer_size = @@session.join_buffer_size; + + +--echo '#---------------------FN_DYNVARS_001_11----------------------#' +############################################################################## +# Check if join_buffer_size can be accessed with and without @@ sign # +############################################################################## + +SET join_buffer_size = 1; +SELECT @@join_buffer_size=8200 OR @@join_buffer_size= 8228; +--Error ER_UNKNOWN_TABLE +SELECT local.join_buffer_size; +--Error ER_UNKNOWN_TABLE +SELECT session.join_buffer_size; +--Error ER_BAD_FIELD_ERROR +SELECT join_buffer_size = @@session.join_buffer_size; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.join_buffer_size = @start_global_value; +SELECT @@global.join_buffer_size; +SET @@session.join_buffer_size = @start_session_value; +SELECT @@session.join_buffer_size; + + +######################################################## +# END OF join_buffer_size TESTS # +######################################################## + diff --git a/mysql-test/include/key_buffer_size_basic.inc b/mysql-test/include/key_buffer_size_basic.inc new file mode 100644 index 00000000000..996a9e712f9 --- /dev/null +++ b/mysql-test/include/key_buffer_size_basic.inc @@ -0,0 +1,187 @@ +############## mysql-test\t\key_buffer_size_basic.test ######################## +# # +# Variable Name: key_buffer_size # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 131072 # +# Range:8-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable key_buffer_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### +# Changes: # +# 2008-03-06 hhunger Got "lost connections with 5.1.24 # +######################################################################## + +--source include/load_sysvars.inc + +######################################################################## +# START OF key_buffer_size TESTS # +######################################################################## + +--disable_warnings +######################################################################## +# Saving initial value of key_buffer_size in a temporary variable # +######################################################################## + +SET @start_value = @@global.key_buffer_size; +SELECT @start_value; + + +--echo '#--------------------FN_DYNVARS_055_01------------------------#' +######################################################################## +# Display the DEFAULT value of key_buffer_size # +######################################################################## + +SET @@global.key_buffer_size = 99; +--Error ER_NO_DEFAULT +SET @@global.key_buffer_size = DEFAULT; +--echo 'Bug# 34878: This variable has default value according to documentation'; +SELECT @@global.key_buffer_size = @min_key_buffer_size; + + +--echo '#---------------------FN_DYNVARS_055_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.key_buffer_size = @start_value; +SELECT @@global.key_buffer_size = @start_value; + +--echo '#--------------------FN_DYNVARS_055_03------------------------#' +######################################################################## +# Change the value of key_buffer_size to a valid value # +######################################################################## + +SET @@global.key_buffer_size = @min_key_buffer_size; +SELECT @@global.key_buffer_size= @min_key_buffer_size; +--disable_warnings +#Due to "lost connection" +#SET @@global.key_buffer_size = 4294967295; +--enable_warnings +#SELECT @@global.key_buffer_size; +SET @@global.key_buffer_size = 1800; +SELECT @@global.key_buffer_size = @min_key_buffer_size; +SET @@global.key_buffer_size = 65535; +SELECT @@global.key_buffer_size; +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + + +--echo '#--------------------FN_DYNVARS_055_04-------------------------#' +########################################################################### +# Change the value of key_buffer_size to invalid value # +########################################################################### + +# Due to "lost connection" +#SET @@global.key_buffer_size = -1; +#SELECT @@global.key_buffer_size; +#SET @@global.key_buffer_size = 100000000000; +#SELECT @@global.key_buffer_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_buffer_size = 10000.01; +SELECT @@global.key_buffer_size; +#SET @@global.key_buffer_size = -1024; +#SELECT @@global.key_buffer_size; +SET @@global.key_buffer_size = 4; +SELECT @@global.key_buffer_size = @min_key_buffer_size; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_buffer_size = ON; +SELECT @@global.key_buffer_size = @min_key_buffer_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_buffer_size = 'test'; +SELECT @@global.key_buffer_size = @min_key_buffer_size; + + +--echo '#-------------------FN_DYNVARS_055_05----------------------------#' +########################################################################### +# Test if accessing session key_buffer_size gives error # +########################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.key_buffer_size = 0; +SELECT @@key_buffer_size = @min_key_buffer_size; + + +--echo '#----------------------FN_DYNVARS_055_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.key_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_buffer_size'; + +SELECT @@key_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_buffer_size'; + + +--echo '#---------------------FN_DYNVARS_055_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.key_buffer_size = TRUE; +SELECT @@global.key_buffer_size = @min_key_buffer_size; +SET @@global.key_buffer_size = FALSE; +SELECT @@global.key_buffer_size = @min_key_buffer_size; + + +--echo '#---------------------FN_DYNVARS_055_08----------------------#' +##################################################################### +# Check if accessing variable with SESSION,LOCAL and without SCOPE # +# points to same session variable # +##################################################################### + +# due to differences in contents of the warnings +--disable_warnings +SET @@global.key_buffer_size = @min_key_buffer_size; +SELECT @@key_buffer_size = @@global.key_buffer_size; +--enable_warnings + +--echo '#---------------------FN_DYNVARS_055_09----------------------#' +########################################################################## +# Check if key_buffer_size can be accessed with and without @@ sign # +########################################################################## + +--Error ER_GLOBAL_VARIABLE +SET key_buffer_size = @min_key_buffer_size; +SELECT @@key_buffer_size = @min_key_buffer_size; +--Error ER_PARSE_ERROR +SET local.key_buffer_size = 10; +--Error ER_UNKNOWN_TABLE +SELECT local.key_buffer_size; +--Error ER_PARSE_ERROR +SET global.key_buffer_size = 10; +--Error ER_UNKNOWN_TABLE +SELECT global.key_buffer_size; +--Error ER_BAD_FIELD_ERROR +SELECT key_buffer_size = @@session.key_buffer_size; + + +############################## +# Restore initial value # +############################## + +SET @@global.key_buffer_size = @start_value; +SELECT @@global.key_buffer_size; + +--enable_warnings +####################################################################### +# END OF key_buffer_size TESTS # +####################################################################### diff --git a/mysql-test/include/key_cache_age_threshold_basic.inc b/mysql-test/include/key_cache_age_threshold_basic.inc new file mode 100644 index 00000000000..7841ad2cedc --- /dev/null +++ b/mysql-test/include/key_cache_age_threshold_basic.inc @@ -0,0 +1,180 @@ +############## mysql-test\t\key_cache_age_threshold_basic.test ############### +# # +# Variable Name: key_cache_age_threshold # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 300 # +# Range: 100-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable key_cache_age_threshold # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +######################################################################## +# START OF key_cache_age_threshold TESTS # +######################################################################## + + +############################################################################# +# Saving initial value of key_cache_age_threshold in a temporary variable # +############################################################################# + +SET @start_value = @@global.key_cache_age_threshold; +SELECT @start_value; + + +--echo '#--------------------FN_DYNVARS_056_01------------------------#' +################################################################################ +# Display the DEFAULT value of key_cache_age_threshold # +################################################################################ + +SET @@global.key_cache_age_threshold = 99; +--Error ER_NO_DEFAULT +SET @@global.key_cache_age_threshold = DEFAULT; +--echo 'Bug# 34878: This variable has default value according to documentation'; +SELECT @@global.key_cache_age_threshold; + + +--echo '#---------------------FN_DYNVARS_056_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.key_cache_age_threshold = @start_value; +SELECT @@global.key_cache_age_threshold = 300; + + +--echo '#--------------------FN_DYNVARS_056_03------------------------#' +############################################################################### +# Change the value of key_cache_age_threshold to a valid value # +############################################################################### + +SET @@global.key_cache_age_threshold = 100; +SELECT @@global.key_cache_age_threshold; +SET @@global.key_cache_age_threshold = 4294967295; +SELECT @@global.key_cache_age_threshold; +SET @@global.key_cache_age_threshold = 1800; +SELECT @@global.key_cache_age_threshold; +SET @@global.key_cache_age_threshold = 65535; +SELECT @@global.key_cache_age_threshold; +--echo 'Bug# 34877 : Invalid Values are coming in variable on assigning valid values and Out Of Memory Warnings are coming'; + + +--echo '#--------------------FN_DYNVARS_056_04-------------------------#' +########################################################################### +# Change the value of key_cache_age_threshold to invalid value # +########################################################################### + +SET @@global.key_cache_age_threshold = -1; +SELECT @@global.key_cache_age_threshold; +SET @@global.key_cache_age_threshold = 42949672951; +SELECT @@global.key_cache_age_threshold; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_cache_age_threshold = 10000.01; +SELECT @@global.key_cache_age_threshold; +SET @@global.key_cache_age_threshold = -1024; +SELECT @@global.key_cache_age_threshold; +SET @@global.key_cache_age_threshold = 99; +SELECT @@global.key_cache_age_threshold; + +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_cache_age_threshold = ON; +SELECT @@global.key_cache_age_threshold; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_cache_age_threshold = 'test'; +SELECT @@global.key_cache_age_threshold; + + +--echo '#-------------------FN_DYNVARS_056_05----------------------------#' +########################################################################### +# Test if accessing session key_cache_age_threshold gives error # +########################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.key_cache_age_threshold = 0; +--Error ER_INCORRECT_GLOBAL_LOCAL_VAR +SELECT @@session.key_cache_age_threshold; + + +--echo '#----------------------FN_DYNVARS_056_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.key_cache_age_threshold = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_cache_age_threshold'; + +SELECT @@key_cache_age_threshold = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_cache_age_threshold'; + + +--echo '#---------------------FN_DYNVARS_056_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.key_cache_age_threshold = TRUE; +SELECT @@global.key_cache_age_threshold; +SET @@global.key_cache_age_threshold = FALSE; +SELECT @@global.key_cache_age_threshold; + + +--echo '#---------------------FN_DYNVARS_056_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.key_cache_age_threshold = 101; +SELECT @@key_cache_age_threshold = @@global.key_cache_age_threshold; + + +--echo '#---------------------FN_DYNVARS_056_09----------------------#' +########################################################################## ####### +# Check if key_cache_age_threshold can be accessed with and without @@ sign # +################################################################################## + +--Error ER_GLOBAL_VARIABLE +SET key_cache_age_threshold = 8000; +SELECT @@key_cache_age_threshold; +--Error ER_PARSE_ERROR +SET local.key_cache_age_threshold = 10; +--Error ER_UNKNOWN_TABLE +SELECT local.key_cache_age_threshold; +--Error ER_PARSE_ERROR +SET global.key_cache_age_threshold = 10; +--Error ER_UNKNOWN_TABLE +SELECT global.key_cache_age_threshold; +--Error ER_BAD_FIELD_ERROR +SELECT key_cache_age_threshold = @@session.key_cache_age_threshold; + + +############################## +# Restore initial value # +############################## + +SET @@global.key_cache_age_threshold = @start_value; +SELECT @@global.key_cache_age_threshold; + + +######################################################################## +# END OF key_cache_age_threshold TESTS # +######################################################################## diff --git a/mysql-test/include/key_cache_block_size_basic.inc b/mysql-test/include/key_cache_block_size_basic.inc new file mode 100644 index 00000000000..b12ea45b762 --- /dev/null +++ b/mysql-test/include/key_cache_block_size_basic.inc @@ -0,0 +1,185 @@ +############## mysql-test\t\key_cache_block_size_basic.test ############### +# # +# Variable Name: key_cache_block_size # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric 1024 # +# Default Value: # +# Range: 512-16384 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable key_cache_block_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +##################################################################### +# START OF key_cache_block_size TESTS # +##################################################################### + + +########################################################################## +# Saving initial value of key_cache_block_size in a temporary variable # +########################################################################## + +SET @start_value = @@global.key_cache_block_size; +SELECT @start_value; + + +--echo '#--------------------FN_DYNVARS_057_01------------------------#' +################################################################################ +# Display the DEFAULT value of key_cache_block_size # +################################################################################ + +SET @@global.key_cache_block_size = 600; +--Error ER_NO_DEFAULT +SET @@global.key_cache_block_size = DEFAULT; +--echo 'Bug# 34877 : Invalid Values are coming in variable on assigning valid values and Out Of Memory Warnings are coming'; +SELECT @@global.key_cache_block_size; + + +--echo '#---------------------FN_DYNVARS_057_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.key_cache_block_size = @start_value; +SELECT @@global.key_cache_block_size = 1024; + + +--echo '#--------------------FN_DYNVARS_057_03------------------------#' +############################################################################### +# Change the value of key_cache_block_size to a valid value # +############################################################################### + +SET @@global.key_cache_block_size = 1024; +SELECT @@global.key_cache_block_size; +SET @@global.key_cache_block_size = 16384; +SELECT @@global.key_cache_block_size; +SET @@global.key_cache_block_size = 1800; +SELECT @@global.key_cache_block_size; +SET @@global.key_cache_block_size = 16383; +SELECT @@global.key_cache_block_size; +--echo 'Bug# 34877 : Invalid Values are coming in variable on assigning valid values and Out Of Memory Warnings are coming'; + + +--echo '#--------------------FN_DYNVARS_057_04-------------------------#' +########################################################################### +# Change the value of key_cache_block_size to invalid value # +########################################################################### + +SET @@global.key_cache_block_size = -1; +SELECT @@global.key_cache_block_size; +SET @@global.key_cache_block_size = 42949672951; +SELECT @@global.key_cache_block_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_cache_block_size = 10000.01; +SELECT @@global.key_cache_block_size; +SET @@global.key_cache_block_size = -1024; +SELECT @@global.key_cache_block_size; +SET @@global.key_cache_block_size = 256; +SELECT @@global.key_cache_block_size; +SET @@global.key_cache_block_size = 511; +SELECT @@global.key_cache_block_size; +SET @@global.key_cache_block_size = 16385; +SELECT @@global.key_cache_block_size; + +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_cache_block_size = ON; +SELECT @@global.key_cache_block_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_cache_block_size = 'test'; +SELECT @@global.key_cache_block_size; + + +--echo '#-------------------FN_DYNVARS_057_05----------------------------#' +########################################################################### +# Test if accessing session key_cache_block_size gives error # +########################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.key_cache_block_size = 0; +--Error ER_INCORRECT_GLOBAL_LOCAL_VAR +SELECT @@session.key_cache_block_size; + + +--echo '#----------------------FN_DYNVARS_057_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.key_cache_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_cache_block_size'; + +SELECT @@key_cache_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_cache_block_size'; + + +--echo '#---------------------FN_DYNVARS_057_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.key_cache_block_size = TRUE; +SELECT @@global.key_cache_block_size; +SET @@global.key_cache_block_size = FALSE; +SELECT @@global.key_cache_block_size; + + +--echo '#---------------------FN_DYNVARS_057_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.key_cache_block_size = 1024; +SELECT @@key_cache_block_size = @@global.key_cache_block_size; + + +--echo '#---------------------FN_DYNVARS_057_09----------------------#' +############################################################################### +# Check if key_cache_block_size can be accessed with and without @@ sign # +###############################################################################; + +--Error ER_GLOBAL_VARIABLE +SET key_cache_block_size = 8000; +SELECT @@key_cache_block_size; +--Error ER_PARSE_ERROR +SET local.key_cache_block_size = 10; +--Error ER_UNKNOWN_TABLE +SELECT local.key_cache_block_size; +--Error ER_PARSE_ERROR +SET global.key_cache_block_size = 10; +--Error ER_UNKNOWN_TABLE +SELECT global.key_cache_block_size; +--Error ER_BAD_FIELD_ERROR +SELECT key_cache_block_size = @@session.key_cache_block_size; + + +############################## +# Restore initial value # +############################## + +SET @@global.key_cache_block_size = @start_value; +SELECT @@global.key_cache_block_size; + + +##################################################################### +# END OF key_cache_block_size TESTS # +##################################################################### + diff --git a/mysql-test/include/key_cache_division_limit_basic.inc b/mysql-test/include/key_cache_division_limit_basic.inc new file mode 100644 index 00000000000..a2cc49a1f38 --- /dev/null +++ b/mysql-test/include/key_cache_division_limit_basic.inc @@ -0,0 +1,184 @@ +############## mysql-test\t\key_cache_division_limit_basic.test ############### +# # +# Variable Name: key_cache_division_limit # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 100 # +# Range: 1-100 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable key_cache_division_limit # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +##################################################################### +# START OF key_cache_division_limit TESTS # +##################################################################### + + +############################################################################## +# Saving initial value of key_cache_division_limit in a temporary variable # +############################################################################## + +SET @start_value = @@global.key_cache_division_limit; +SELECT @start_value; + + +--echo '#--------------------FN_DYNVARS_058_01------------------------#' +################################################################################ +# Display the DEFAULT value of key_cache_division_limit # +################################################################################ + +SET @@global.key_cache_division_limit = 50; +--Error ER_NO_DEFAULT +SET @@global.key_cache_division_limit = DEFAULT; +--echo 'Bug# 34878: This variable has default value according to documentation'; +SELECT @@global.key_cache_division_limit; + + +--echo '#---------------------FN_DYNVARS_058_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.key_cache_division_limit = @start_value; +SELECT @@global.key_cache_division_limit = 100; + + +--echo '#--------------------FN_DYNVARS_058_03------------------------#' +############################################################################### +# Change the value of key_cache_division_limit to a valid value # +############################################################################### + +SET @@global.key_cache_division_limit = 1; +SELECT @@global.key_cache_division_limit; +SET @@global.key_cache_division_limit = 50; +SELECT @@global.key_cache_division_limit; +SET @@global.key_cache_division_limit = 99; +SELECT @@global.key_cache_division_limit; +SET @@global.key_cache_division_limit = 2; +SELECT @@global.key_cache_division_limit; + + +--echo '#--------------------FN_DYNVARS_058_04-------------------------#' +########################################################################### +# Change the value of key_cache_division_limit to invalid value # +########################################################################### + +SET @@global.key_cache_division_limit = -1; +SELECT @@global.key_cache_division_limit; +SET @@global.key_cache_division_limit = 101; +SELECT @@global.key_cache_division_limit; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_cache_division_limit = 10000.01; +SELECT @@global.key_cache_division_limit; +SET @@global.key_cache_division_limit = -1024; +SELECT @@global.key_cache_division_limit; +SET @@global.key_cache_division_limit = 0; +SELECT @@global.key_cache_division_limit; +SET @@global.key_cache_division_limit = 200; +SELECT @@global.key_cache_division_limit; +SET @@global.key_cache_division_limit = 65535; +SELECT @@global.key_cache_division_limit; + +echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_cache_division_limit = ON; +SELECT @@global.key_cache_division_limit; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.key_cache_division_limit = 'test'; +SELECT @@global.key_cache_division_limit; + + +--echo '#-------------------FN_DYNVARS_058_05----------------------------#' +########################################################################### +# Test if accessing session key_cache_division_limit gives error # +########################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.key_cache_division_limit = 0; +--Error ER_INCORRECT_GLOBAL_LOCAL_VAR +SELECT @@session.key_cache_division_limit; + + +--echo '#----------------------FN_DYNVARS_058_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.key_cache_division_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_cache_division_limit'; + +SELECT @@key_cache_division_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_cache_division_limit'; + + +--echo '#---------------------FN_DYNVARS_058_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.key_cache_division_limit = TRUE; +SELECT @@global.key_cache_division_limit; +SET @@global.key_cache_division_limit = FALSE; +SELECT @@global.key_cache_division_limit; + + +--echo '#---------------------FN_DYNVARS_058_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.key_cache_division_limit = 90; +SELECT @@key_cache_division_limit = @@global.key_cache_division_limit; + + +--echo '#---------------------FN_DYNVARS_058_09----------------------#' +############################################################################### +# Check if key_cache_division_limit can be accessed with and without @@ sign # +###############################################################################; + +--Error ER_GLOBAL_VARIABLE +SET key_cache_division_limit = 80; +SELECT @@key_cache_division_limit; +--Error ER_PARSE_ERROR +SET local.key_cache_division_limit = 10; +--Error ER_UNKNOWN_TABLE +SELECT local.key_cache_division_limit; +--Error ER_PARSE_ERROR +SET global.key_cache_division_limit = 10; +--Error ER_UNKNOWN_TABLE +SELECT global.key_cache_division_limit; +--Error ER_BAD_FIELD_ERROR +SELECT key_cache_division_limit = @@session.key_cache_division_limit; + + +############################## +# Restore initial value # +############################## + +SET @@global.key_cache_division_limit = @start_value; +SELECT @@global.key_cache_division_limit; + + +##################################################################### +# END OF key_cache_division_limit TESTS # +##################################################################### + diff --git a/mysql-test/include/load_sysvars.inc b/mysql-test/include/load_sysvars.inc index 84e00d74edb..bcae9fa8d9c 100644 --- a/mysql-test/include/load_sysvars.inc +++ b/mysql-test/include/load_sysvars.inc @@ -1,14 +1,15 @@ # -# This script is included by every test to include system dependant variables' -# default, minimum and maximum values +# This script is included by tests of system variables to include system +# dependant values for the variables: default, minimum and maximum values # - -if (`select convert(@@version_compile_os using latin1) IN ("Win32","Win64","Windows")`) +if (`SELECT convert(@@version_compile_os using latin1) + IN ('Win32','Win64','Windows')`) { --source include/windows_sys_vars.inc } -if (`select convert(@@version_compile_os using latin1) IN ("suse-linux-gnu","redhat-linux-gnu","pc-solaris2.10")`) +if (!`SELECT convert(@@version_compile_os using latin1) + IN ('Win32','Win64','Windows')`) { --source include/linux_sys_vars.inc } diff --git a/mysql-test/include/log_warnings_basic.inc b/mysql-test/include/log_warnings_basic.inc new file mode 100644 index 00000000000..cd7e1023649 --- /dev/null +++ b/mysql-test/include/log_warnings_basic.inc @@ -0,0 +1,210 @@ +############## mysql-test\t\log_warnings_basic.test ############### +# # +# Variable Name: log_warnings # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 1 # +# Range: - # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable log_warnings # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +############################################################ +# START OF log_warnings TESTS # +############################################################ + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.log_warnings; +SELECT @start_global_value; +SET @start_session_value = @@session.log_warnings; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_067_01-------------------------#' +######################################################################## +# Display the DEFAULT value of log_warnings # +######################################################################## + +SET @@global.log_warnings = 100; +SET @@global.log_warnings = DEFAULT; +SELECT @@global.log_warnings; + +SET @@session.log_warnings = 200; +SET @@session.log_warnings = DEFAULT; +SELECT @@session.log_warnings; + + +--echo '#--------------------FN_DYNVARS_067_02-------------------------#' +######################################################################## +# Check the DEFAULT value of log_warnings # +######################################################################## + +SET @@global.log_warnings = DEFAULT; +SELECT @@global.log_warnings = 1; + +SET @@session.log_warnings = DEFAULT; +SELECT @@session.log_warnings = 1; + + +--echo '#--------------------FN_DYNVARS_067_03-------------------------#' +###################################################################### +# Change the value of log_warnings to a valid value for GLOBAL Scope # +###################################################################### + +SET @@global.log_warnings = 0; +SELECT @@global.log_warnings; +SET @@global.log_warnings = 1; +SELECT @@global.log_warnings; +SET @@global.log_warnings = 60020; +SELECT @@global.log_warnings; +SET @@global.log_warnings = 65535; +SELECT @@global.log_warnings; +SET @@global.log_warnings = 65536; +SELECT @@global.log_warnings; + + +--echo '#--------------------FN_DYNVARS_067_04-------------------------#' +####################################################################### +# Change the value of log_warnings to a valid value for SESSION Scope # +####################################################################### + +SET @@session.log_warnings = 0; +SELECT @@session.log_warnings; +SET @@session.log_warnings = 1; +SELECT @@session.log_warnings; +SET @@session.log_warnings = 50050; +SELECT @@session.log_warnings; +SET @@session.log_warnings = 65535; +SELECT @@session.log_warnings; +SET @@session.log_warnings = 65550; +SELECT @@session.log_warnings; + + +--echo '#------------------FN_DYNVARS_067_05-----------------------#' +######################################################## +# Change the value of log_warnings to an invalid value # +######################################################## + +SET @@global.log_warnings = 100000000000; +SELECT @@global.log_warnings; +SET @@global.log_warnings = -1024; +SELECT @@global.log_warnings; +--Error ER_PARSE_ERROR +SET @@global.log_warnings = 65530.34.; +SELECT @@global.log_warnings; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.log_warnings = test; +SELECT @@global.log_warnings; + +SET @@session.log_warnings = 100000000000; +SELECT @@session.log_warnings; +SET @@session.log_warnings = -2; +SELECT @@session.log_warnings; +--Error ER_PARSE_ERROR +SET @@session.log_warnings = 65530.34.; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.log_warnings = test; +SELECT @@session.log_warnings; + + +--echo '#------------------FN_DYNVARS_067_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.log_warnings = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_warnings'; + +--echo '#------------------FN_DYNVARS_067_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.log_warnings = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='log_warnings'; + + +--echo '#------------------FN_DYNVARS_067_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.log_warnings = TRUE; +SELECT @@global.log_warnings; +SET @@global.log_warnings = FALSE; +SELECT @@global.log_warnings; + + +--echo '#---------------------FN_DYNVARS_067_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + +SET @@global.log_warnings = 10; +SELECT @@log_warnings = @@global.log_warnings; + + +--echo '#---------------------FN_DYNVARS_067_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@log_warnings = 100; +SELECT @@log_warnings = @@local.log_warnings; +SELECT @@local.log_warnings = @@session.log_warnings; + + +--echo '#---------------------FN_DYNVARS_067_11----------------------#' +####################################################################### +# Check if log_warnings can be accessed with and without @@ sign # +####################################################################### + +SET log_warnings = 1; +SELECT @@log_warnings; +--Error ER_UNKNOWN_TABLE +SELECT local.log_warnings; +--Error ER_UNKNOWN_TABLE +SELECT session.log_warnings; +--Error ER_BAD_FIELD_ERROR +SELECT log_warnings = @@session.log_warnings; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.log_warnings = @start_global_value; +SELECT @@global.log_warnings; +SET @@session.log_warnings = @start_session_value; +SELECT @@session.log_warnings; + + +############################################################# +# END OF log_warnings TESTS # +############################################################# + diff --git a/mysql-test/include/max_binlog_cache_size_basic.inc b/mysql-test/include/max_binlog_cache_size_basic.inc new file mode 100644 index 00000000000..9f3416d2e31 --- /dev/null +++ b/mysql-test/include/max_binlog_cache_size_basic.inc @@ -0,0 +1,187 @@ +############## mysql-test\t\max_binlog_cache_size_basic.test ############### +# # +# Variable Name: max_binlog_cache_size # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value:4294967295 # +# Range: 4096-4294967295 # +# # +# # +# # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable max_binlog_cache_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +######################################################################## +# START OF max_binlog_cache_size TESTS # +######################################################################## + + +######################################################################## +# Saving initial value of max_binlog_cache_size in a temporary variable# +######################################################################## + +SET @start_value = @@global.max_binlog_cache_size; +SELECT @start_value; + + +--echo '#--------------------FN_DYNVARS_072_01------------------------#' +######################################################################## +# Display the DEFAULT value of max_binlog_cache_size # +######################################################################## + +SET @@global.max_binlog_cache_size = 5000; +SET @@global.max_binlog_cache_size = DEFAULT; +SELECT @@global.max_binlog_cache_size; + + +--echo '#---------------------FN_DYNVARS_072_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.max_binlog_cache_size = @start_value; +SELECT @@global.max_binlog_cache_size = 4294967295; +--echo 'Bug# 34876: Incorrect Default Value is assigned to variable'; + +--echo '#--------------------FN_DYNVARS_072_03------------------------#' +######################################################################## +# Change the value of max_binlog_cache_size to a valid value # +######################################################################## + +SET @@global.max_binlog_cache_size = 4096; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = 4294967295; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = 4294967294; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = 4097; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = 65535; +SELECT @@global.max_binlog_cache_size; +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + + +--echo '#--------------------FN_DYNVARS_072_04-------------------------#' +########################################################################### +# Change the value of max_binlog_cache_size to invalid value # +########################################################################### + +SET @@global.max_binlog_cache_size = -1; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = 100000000000; +SELECT @@global.max_binlog_cache_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_binlog_cache_size = 10000.01; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = -1024; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = 1024; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = 4294967296; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = 4095; +SELECT @@global.max_binlog_cache_size; + +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_binlog_cache_size = ON; +SELECT @@global.max_binlog_cache_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_binlog_cache_size = 'test'; +SELECT @@global.max_binlog_cache_size; + + +--echo '#-------------------FN_DYNVARS_072_05----------------------------#' +########################################################################### +# Test if accessing session max_binlog_cache_size gives error # +########################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.max_binlog_cache_size = 4096; +--Error ER_INCORRECT_GLOBAL_LOCAL_VAR +SELECT @@session.max_binlog_cache_size; + + +--echo '#----------------------FN_DYNVARS_072_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.max_binlog_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_binlog_cache_size'; + +SELECT @@max_binlog_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_binlog_cache_size'; + + +--echo '#---------------------FN_DYNVARS_072_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.max_binlog_cache_size = TRUE; +SELECT @@global.max_binlog_cache_size; +SET @@global.max_binlog_cache_size = FALSE; +SELECT @@global.max_binlog_cache_size; + + +--echo '#---------------------FN_DYNVARS_072_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.max_binlog_cache_size = 5000; +SELECT @@max_binlog_cache_size = @@global.max_binlog_cache_size; + + +--echo '#---------------------FN_DYNVARS_072_09----------------------#' +################################################################################ +# Check if max_binlog_cache_size can be accessed with and without @@ sign # +################################################################################ + +--Error ER_GLOBAL_VARIABLE +SET max_binlog_cache_size = 6000; +SELECT @@max_binlog_cache_size; +--Error ER_PARSE_ERROR +SET local.max_binlog_cache_size = 7000; +--Error ER_UNKNOWN_TABLE +SELECT local.max_binlog_cache_size; +--Error ER_PARSE_ERROR +SET global.max_binlog_cache_size = 8000; +--Error ER_UNKNOWN_TABLE +SELECT global.max_binlog_cache_size; +--Error ER_BAD_FIELD_ERROR +SELECT max_binlog_cache_size = @@session.max_binlog_cache_size; + + +############################## +# Restore initial value # +############################## + +SET @@global.max_binlog_cache_size = @start_value; +SELECT @@global.max_binlog_cache_size; + + +######################################################################## +# END OF max_binlog_cache_size TESTS # +######################################################################## diff --git a/mysql-test/include/max_connect_errors_basic.inc b/mysql-test/include/max_connect_errors_basic.inc new file mode 100644 index 00000000000..530022652a1 --- /dev/null +++ b/mysql-test/include/max_connect_errors_basic.inc @@ -0,0 +1,182 @@ +############## mysql-test\t\max_connect_errors_basic.test ############### +# # +# Variable Name: max_connect_errors # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 10 # +# Range: 1-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable max_connect_errors # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +################################################################## +# START OF max_connect_errors TESTS # +################################################################## + + +###################################################################### +# Saving initial value of max_connect_errors in a temporary variable # +###################################################################### + +SET @start_value = @@global.max_connect_errors; +SELECT @start_value; + + +--echo '#--------------------FN_DYNVARS_073_01------------------------#' +################################################################## +# Display the DEFAULT value of max_connect_errors # +################################################################## + +SET @@global.max_connect_errors = 5000; +SET @@global.max_connect_errors = DEFAULT; +SELECT @@global.max_connect_errors; +--echo 'Bug# 34876: This variable has invalid default value as compared to documentation'; + +--echo '#---------------------FN_DYNVARS_073_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.max_connect_errors = @start_value; +SELECT @@global.max_connect_errors = 10; + +--echo '#--------------------FN_DYNVARS_073_03------------------------#' +################################################################## +# Change the value of max_connect_errors to a valid value # +################################################################## + +SET @@global.max_connect_errors = 4096; +SELECT @@global.max_connect_errors; +SET @@global.max_connect_errors = 4294967294; +SELECT @@global.max_connect_errors; +SET @@global.max_connect_errors = 4294967295; +SELECT @@global.max_connect_errors; +SET @@global.max_connect_errors = 1; +SELECT @@global.max_connect_errors; +SET @@global.max_connect_errors = 2; +SELECT @@global.max_connect_errors; +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + + +--echo '#--------------------FN_DYNVARS_073_04-------------------------#' +##################################################################### +# Change the value of max_connect_errors to invalid value # +##################################################################### + +SET @@global.max_connect_errors = -1; +SELECT @@global.max_connect_errors; +SET @@global.max_connect_errors = 100000000000; +SELECT @@global.max_connect_errors; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_connect_errors = 10000.01; +SELECT @@global.max_connect_errors; +SET @@global.max_connect_errors = -1024; +SELECT @@global.max_connect_errors; +SET @@global.max_connect_errors = 0; +SELECT @@global.max_connect_errors; +SET @@global.max_connect_errors = 4294967296; +SELECT @@global.max_connect_errors; + +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_connect_errors = ON; +SELECT @@global.max_connect_errors; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_connect_errors = 'test'; +SELECT @@global.max_connect_errors; + + +--echo '#-------------------FN_DYNVARS_073_05----------------------------#' +##################################################################### +# Test if accessing session max_connect_errors gives error # +##################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.max_connect_errors = 4096; +--Error ER_INCORRECT_GLOBAL_LOCAL_VAR +SELECT @@session.max_connect_errors; + + +--echo '#----------------------FN_DYNVARS_073_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.max_connect_errors = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_connect_errors'; + +SELECT @@max_connect_errors = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_connect_errors'; + + +--echo '#---------------------FN_DYNVARS_073_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.max_connect_errors = TRUE; +SELECT @@global.max_connect_errors; +SET @@global.max_connect_errors = FALSE; +SELECT @@global.max_connect_errors; + + +--echo '#---------------------FN_DYNVARS_073_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.max_connect_errors = 5000; +SELECT @@max_connect_errors = @@global.max_connect_errors; + + +--echo '#---------------------FN_DYNVARS_073_09----------------------#' +########################################################################## +# Check if max_connect_errors can be accessed with and without @@ sign # +########################################################################## + +--Error ER_GLOBAL_VARIABLE +SET max_connect_errors = 6000; +SELECT @@max_connect_errors; +--Error ER_PARSE_ERROR +SET local.max_connect_errors = 7000; +--Error ER_UNKNOWN_TABLE +SELECT local.max_connect_errors; +--Error ER_PARSE_ERROR +SET global.max_connect_errors = 8000; +--Error ER_UNKNOWN_TABLE +SELECT global.max_connect_errors; +--Error ER_BAD_FIELD_ERROR +SELECT max_connect_errors = @@session.max_connect_errors; + + +############################## +# Restore initial value # +############################## + +SET @@global.max_connect_errors = @start_value; +SELECT @@global.max_connect_errors; + + +################################################################## +# END OF max_connect_errors TESTS # +################################################################## + diff --git a/mysql-test/include/max_heap_table_size_basic.inc b/mysql-test/include/max_heap_table_size_basic.inc new file mode 100644 index 00000000000..d07ae094cde --- /dev/null +++ b/mysql-test/include/max_heap_table_size_basic.inc @@ -0,0 +1,222 @@ +############## mysql-test\t\max_heap_table_size_basic.test ############### +# # +# Variable Name: max_heap_table_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 16777216 # +# Range: 16384-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable max_heap_table_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +############################################################### +# START OF max_heap_table_size TESTS # +############################################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.max_heap_table_size; +SELECT @start_global_value; +SET @start_session_value = @@session.max_heap_table_size; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_077_01-------------------------#' +############################################################### +# Display the DEFAULT value of max_heap_table_size # +############################################################### + +SET @@global.max_heap_table_size = 1677721610; +SET @@global.max_heap_table_size = DEFAULT; +SELECT @@global.max_heap_table_size; + +SET @@session.max_heap_table_size = 1677721610; +SET @@session.max_heap_table_size = DEFAULT; +SELECT @@session.max_heap_table_size; + + +--echo '#--------------------FN_DYNVARS_077_02-------------------------#' +################################################################## +# Check the DEFAULT value of max_heap_table_size # +################################################################## + +SET @@global.max_heap_table_size = DEFAULT; +SELECT @@global.max_heap_table_size = 16777216; + +SET @@session.max_heap_table_size = DEFAULT; +SELECT @@session.max_heap_table_size = 16777216; + + +--echo '#--------------------FN_DYNVARS_077_03-------------------------#' +############################################################################ +# Change the value of max_heap_table_size to a valid value for GLOBAL Scope # +############################################################################ + +SET @@global.max_heap_table_size = 16384; +SELECT @@global.max_heap_table_size; +SET @@global.max_heap_table_size = 16385; +SELECT @@global.max_heap_table_size; +SET @@global.max_heap_table_size = 65535; +SELECT @@global.max_heap_table_size; +SET @@global.max_heap_table_size = 4294967294; +SELECT @@global.max_heap_table_size; +SET @@global.max_heap_table_size = 4294967295; +SELECT @@global.max_heap_table_size; +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + + +--echo '#--------------------FN_DYNVARS_077_04-------------------------#' +############################################################################# +# Change the value of max_heap_table_size to a valid value for SESSION Scope # +############################################################################# + +SET @@session.max_heap_table_size = 16384; +SELECT @@session.max_heap_table_size; +SET @@session.max_heap_table_size = 16385; +SELECT @@session.max_heap_table_size; +SET @@session.max_heap_table_size = 65535; +SELECT @@session.max_heap_table_size; +SET @@session.max_heap_table_size = 4294967294; +SELECT @@session.max_heap_table_size; +SET @@session.max_heap_table_size = 4294967295; +SELECT @@session.max_heap_table_size; +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + + +--echo '#------------------FN_DYNVARS_077_05-----------------------#' +############################################################## +# Change the value of max_heap_table_size to an invalid value # +############################################################## + +SET @@global.max_heap_table_size = -1; +SELECT @@global.max_heap_table_size; +SET @@global.max_heap_table_size = -1024; +SELECT @@global.max_heap_table_size; +SET @@global.max_heap_table_size = 1024; +SELECT @@global.max_heap_table_size; +SET @@global.max_heap_table_size = 16383; +SELECT @@global.max_heap_table_size; +SET @@global.max_heap_table_size = 4294967296; +SELECT @@global.max_heap_table_size; +--Error ER_PARSE_ERROR +SET @@global.max_heap_table_size = 65530.34.; +SELECT @@global.max_heap_table_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_heap_table_size = test; +SELECT @@global.max_heap_table_size; + +SET @@session.max_heap_table_size = -1; +SELECT @@session.max_heap_table_size; +SET @@session.max_heap_table_size = 16383; +SELECT @@session.max_heap_table_size; +SET @@session.max_heap_table_size = 4294967296; +SELECT @@session.max_heap_table_size; +--Error ER_PARSE_ERROR +SET @@session.max_heap_table_size = 65530.34.; +SET @@session.max_heap_table_size = 10737418241; +SELECT @@session.max_heap_table_size; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.max_heap_table_size = test; +SELECT @@session.max_heap_table_size; + + +--echo '#------------------FN_DYNVARS_077_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.max_heap_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_heap_table_size'; + +--echo '#------------------FN_DYNVARS_077_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.max_heap_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_heap_table_size'; + + +--echo '#------------------FN_DYNVARS_077_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.max_heap_table_size = TRUE; +SELECT @@global.max_heap_table_size; +SET @@global.max_heap_table_size = FALSE; +SELECT @@global.max_heap_table_size; + + +--echo '#---------------------FN_DYNVARS_077_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + +SET @@global.max_heap_table_size = 163845; +SELECT @@max_heap_table_size = @@global.max_heap_table_size; + + +--echo '#---------------------FN_DYNVARS_077_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@max_heap_table_size = 16777216; +SELECT @@max_heap_table_size = @@local.max_heap_table_size; +SELECT @@local.max_heap_table_size = @@session.max_heap_table_size; + + +--echo '#---------------------FN_DYNVARS_077_11----------------------#' +############################################################################# +# Check if max_heap_table_size can be accessed with and without @@ sign # +############################################################################# + +SET max_heap_table_size = 316777216; +SELECT @@max_heap_table_size; +--Error ER_UNKNOWN_TABLE +SELECT local.max_heap_table_size; +--Error ER_UNKNOWN_TABLE +SELECT session.max_heap_table_size; +--Error ER_BAD_FIELD_ERROR +SELECT max_heap_table_size = @@session.max_heap_table_size; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.max_heap_table_size = @start_global_value; +SELECT @@global.max_heap_table_size; +SET @@session.max_heap_table_size = @start_session_value; +SELECT @@session.max_heap_table_size; + + +####################################################### +# END OF max_heap_table_size TESTS # +####################################################### + diff --git a/mysql-test/include/max_seeks_for_key_basic.inc b/mysql-test/include/max_seeks_for_key_basic.inc new file mode 100644 index 00000000000..23c3c5b2a95 --- /dev/null +++ b/mysql-test/include/max_seeks_for_key_basic.inc @@ -0,0 +1,213 @@ +############## mysql-test\t\max_seeks_for_key_basic.test ############### +# # +# Variable Name: max_seeks_for_key # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 4294967295 # +# Range: 1-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable max_seeks_for_key # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +################################################################# +# START OF max_seeks_for_key TESTS # +################################################################# + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.max_seeks_for_key; +SELECT @start_global_value; +SET @start_session_value = @@session.max_seeks_for_key; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_083_01-------------------------#' +################################################################# +# Display the DEFAULT value of max_seeks_for_key # +################################################################# + +SET @@global.max_seeks_for_key = 100; +SET @@global.max_seeks_for_key = DEFAULT; +SELECT @@global.max_seeks_for_key; + +SET @@session.max_seeks_for_key = 200; +SET @@session.max_seeks_for_key = DEFAULT; +SELECT @@session.max_seeks_for_key; + + +--echo '#--------------------FN_DYNVARS_083_02-------------------------#' +################################################################# +# Check the DEFAULT value of max_seeks_for_key # +################################################################# + +SET @@global.max_seeks_for_key = DEFAULT; +SELECT @@global.max_seeks_for_key = 4294967295; + +SET @@session.max_seeks_for_key = DEFAULT; +SELECT @@session.max_seeks_for_key = 4294967295; + + +--echo '#--------------------FN_DYNVARS_083_03-------------------------#' +########################################################################### +# Change the value of max_seeks_for_key to a valid value for GLOBAL Scope # +########################################################################### + +SET @@global.max_seeks_for_key = 1; +SELECT @@global.max_seeks_for_key; +SET @@global.max_seeks_for_key = 2; +SELECT @@global.max_seeks_for_key; +SET @@global.max_seeks_for_key = 65536; +SELECT @@global.max_seeks_for_key; +SET @@global.max_seeks_for_key = 4294967295; +SELECT @@global.max_seeks_for_key; +SET @@global.max_seeks_for_key = 4294967294; +SELECT @@global.max_seeks_for_key; + + +--echo '#--------------------FN_DYNVARS_083_04-------------------------#' +############################################################################ +# Change the value of max_seeks_for_key to a valid value for SESSION Scope # +############################################################################ +SET @@session.max_seeks_for_key = 1; +SELECT @@session.max_seeks_for_key; +SET @@session.max_seeks_for_key = 2; +SELECT @@session.max_seeks_for_key; +SET @@session.max_seeks_for_key = 4294967295; +SELECT @@session.max_seeks_for_key; +SET @@session.max_seeks_for_key = 4294967294; +SELECT @@session.max_seeks_for_key; +SET @@session.max_seeks_for_key = 65535; +SELECT @@session.max_seeks_for_key; + + +--echo '#------------------FN_DYNVARS_083_05-----------------------#' +############################################################# +# Change the value of max_seeks_for_key to an invalid value # +############################################################# + +SET @@global.max_seeks_for_key = 0; +SELECT @@global.max_seeks_for_key; +SET @@global.max_seeks_for_key = -1024; +SELECT @@global.max_seeks_for_key; +SET @@global.max_seeks_for_key = 4294967296; +SELECT @@global.max_seeks_for_key; +--Error ER_PARSE_ERROR +SET @@global.max_seeks_for_key = 65530.34.; +SELECT @@global.max_seeks_for_key; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_seeks_for_key = test; +SELECT @@global.max_seeks_for_key; + +SET @@session.max_seeks_for_key = 0; +SELECT @@session.max_seeks_for_key; +SET @@session.max_seeks_for_key = -2; +SELECT @@session.max_seeks_for_key; +--Error ER_PARSE_ERROR +SET @@session.max_seeks_for_key = 65530.34.; +SET @@session.max_seeks_for_key = 4294967296; +SELECT @@session.max_seeks_for_key; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.max_seeks_for_key = test; +SELECT @@session.max_seeks_for_key; + + +--echo '#------------------FN_DYNVARS_083_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.max_seeks_for_key = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_seeks_for_key'; + +--echo '#------------------FN_DYNVARS_083_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.max_seeks_for_key = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_seeks_for_key'; + + +--echo '#------------------FN_DYNVARS_083_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.max_seeks_for_key = TRUE; +SELECT @@global.max_seeks_for_key; +SET @@global.max_seeks_for_key = FALSE; +SELECT @@global.max_seeks_for_key; + + +--echo '#---------------------FN_DYNVARS_083_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + +SET @@global.max_seeks_for_key = 10; +SELECT @@max_seeks_for_key = @@global.max_seeks_for_key; + + +--echo '#---------------------FN_DYNVARS_083_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@max_seeks_for_key = 100; +SELECT @@max_seeks_for_key = @@local.max_seeks_for_key; +SELECT @@local.max_seeks_for_key = @@session.max_seeks_for_key; + + +--echo '#---------------------FN_DYNVARS_083_11----------------------#' +############################################################################ +# Check if max_seeks_for_key can be accessed with and without @@ sign # +############################################################################ + +SET max_seeks_for_key = 1; +SELECT @@max_seeks_for_key; +--Error ER_UNKNOWN_TABLE +SELECT local.max_seeks_for_key; +--Error ER_UNKNOWN_TABLE +SELECT session.max_seeks_for_key; +--Error ER_BAD_FIELD_ERROR +SELECT max_seeks_for_key = @@session.max_seeks_for_key; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.max_seeks_for_key = @start_global_value; +SELECT @@global.max_seeks_for_key; +SET @@session.max_seeks_for_key = @start_session_value; +SELECT @@session.max_seeks_for_key; + + +############################################################# +# END OF max_seeks_for_key TESTS # +############################################################# + diff --git a/mysql-test/include/max_tmp_tables_basic.inc b/mysql-test/include/max_tmp_tables_basic.inc new file mode 100644 index 00000000000..e24d97f47dd --- /dev/null +++ b/mysql-test/include/max_tmp_tables_basic.inc @@ -0,0 +1,227 @@ +############## mysql-test\t\max_tmp_tables_basic.test ############### +# # +# Variable Name: max_tmp_tables # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 32 # +# Range: 1-4294967295 # +# # +# # +# # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable max_tmp_tables # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +#################################### +# START OF max_tmp_tables TESTS # +#################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.max_tmp_tables; +SELECT @start_global_value; +SET @start_session_value = @@session.max_tmp_tables; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_086_01-------------------------#' +###################################################### +# Display the DEFAULT value of max_tmp_tables # +###################################################### + +SET @@global.max_tmp_tables = 1000; +SET @@global.max_tmp_tables = DEFAULT; +SELECT @@global.max_tmp_tables; + + +SET @@session.max_tmp_tables = 1000; +SET @@session.max_tmp_tables = DEFAULT; +SELECT @@session.max_tmp_tables; + + +--echo '#--------------------FN_DYNVARS_086_02-------------------------#' +###################################################### +# Check the DEFAULT value of max_tmp_tables # +###################################################### + +SET @@global.max_tmp_tables = DEFAULT; +SELECT @@global.max_tmp_tables = 32; + +SET @@session.max_tmp_tables = DEFAULT; +SELECT @@session.max_tmp_tables = 32; + + + +--echo '#--------------------FN_DYNVARS_086_03-------------------------#' +######################################################################## +# Change the value of max_tmp_tables to a valid value for GLOBAL Scope # +######################################################################## + +SET @@global.max_tmp_tables = 1; +SELECT @@global.max_tmp_tables; +SET @@global.max_tmp_tables = 2; +SELECT @@global.max_tmp_tables; +SET @@global.max_tmp_tables = 65536; +SELECT @@global.max_tmp_tables; +SET @@global.max_tmp_tables = 4294967295; +SELECT @@global.max_tmp_tables; +SET @@global.max_tmp_tables = 4294967294; +SELECT @@global.max_tmp_tables; + +--echo '#--------------------FN_DYNVARS_086_04-------------------------#' +######################################################################### +# Change the value of max_tmp_tables to a valid value for SESSION Scope # +######################################################################### + +SET @@session.max_tmp_tables = 1; +SELECT @@session.max_tmp_tables; + +SET @@session.max_tmp_tables = 2; +SELECT @@session.max_tmp_tables; + +SET @@session.max_tmp_tables = 65536; +SELECT @@session.max_tmp_tables; + +SET @@session.max_tmp_tables = 4294967295; +SELECT @@session.max_tmp_tables; + +SET @@session.max_tmp_tables = 4294967294; +SELECT @@session.max_tmp_tables; + + +--echo '#------------------FN_DYNVARS_086_05-----------------------#' +########################################################## +# Change the value of max_tmp_tables to an invalid value # +########################################################## + +SET @@global.max_tmp_tables = -1024; +SELECT @@global.max_tmp_tables; +SET @@global.max_tmp_tables = 4294967296; +SELECT @@global.max_tmp_tables; +SET @@global.max_tmp_tables = -1; +SELECT @@global.max_tmp_tables; +SET @@global.max_tmp_tables = 429496729500; +SELECT @@global.max_tmp_tables; +--Error ER_PARSE_ERROR +SET @@global.max_tmp_tables = 65530.34.; +SELECT @@global.max_tmp_tables; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_tmp_tables = test; +SELECT @@global.max_tmp_tables; + +SET @@session.max_tmp_tables = 4294967296; +SELECT @@session.max_tmp_tables; +SET @@session.max_tmp_tables = -1; +SELECT @@session.max_tmp_tables; +SET @@session.max_tmp_tables = 429496729500; +SELECT @@session.max_tmp_tables; +SET @@session.max_tmp_tables = -001; +SELECT @@session.max_tmp_tables; +--Error ER_PARSE_ERROR +SET @@session.max_tmp_tables = 65530.34.; +SET @@session.max_tmp_tables = 10737418241; +SELECT @@session.max_tmp_tables; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.max_tmp_tables = test; +SELECT @@session.max_tmp_tables; + + +--echo '#------------------FN_DYNVARS_086_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.max_tmp_tables = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_tmp_tables'; + +--echo '#------------------FN_DYNVARS_086_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.max_tmp_tables = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_tmp_tables'; + + +--echo '#------------------FN_DYNVARS_086_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.max_tmp_tables = TRUE; +SELECT @@global.max_tmp_tables; +SET @@global.max_tmp_tables = FALSE; +SELECT @@global.max_tmp_tables; + + +--echo '#---------------------FN_DYNVARS_086_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + +SET @@global.max_tmp_tables = 20; +SELECT @@max_tmp_tables = @@global.max_tmp_tables; + + +--echo '#---------------------FN_DYNVARS_086_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@max_tmp_tables = 255; +SELECT @@max_tmp_tables = @@local.max_tmp_tables; +SELECT @@local.max_tmp_tables = @@session.max_tmp_tables; + + +--echo '#---------------------FN_DYNVARS_086_11----------------------#' +######################################################################### +# Check if max_tmp_tables can be accessed with and without @@ sign # +######################################################################### + + +SET max_tmp_tables = 102; +SELECT @@max_tmp_tables; +--Error ER_UNKNOWN_TABLE +SELECT local.max_tmp_tables; +--Error ER_UNKNOWN_TABLE +SELECT session.max_tmp_tables; +--Error ER_BAD_FIELD_ERROR +SELECT max_tmp_tables = @@session.max_tmp_tables; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.max_tmp_tables = @start_global_value; +SELECT @@global.max_tmp_tables; +SET @@session.max_tmp_tables = @start_session_value; +SELECT @@session.max_tmp_tables; + + +################################################### +# END OF max_tmp_tables TESTS # +################################################### + diff --git a/mysql-test/include/max_write_lock_count_basic.inc b/mysql-test/include/max_write_lock_count_basic.inc new file mode 100644 index 00000000000..80d5b7cc747 --- /dev/null +++ b/mysql-test/include/max_write_lock_count_basic.inc @@ -0,0 +1,158 @@ +############## mysql-test\t\max_write_lock_count_basic.test ############### +# # +# Variable Name: max_write_lock_count # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 4294967295 # +# Range:1-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable max_write_lock_count # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +########################################## +# START OF max_write_lock_count TESTS # +########################################## + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.max_write_lock_count; +SELECT @start_global_value; + + +--echo '#--------------------FN_DYNVARS_088_01-------------------------#' +############################################################ +# Display the DEFAULT value of max_write_lock_count # +############################################################ + +SET @@global.max_write_lock_count = 1000; +SET @@global.max_write_lock_count = DEFAULT; +SELECT @@global.max_write_lock_count; + + +--echo '#--------------------FN_DYNVARS_088_02-------------------------#' +############################################################ +# Check the DEFAULT value of max_write_lock_count # +############################################################ + +SET @@global.max_write_lock_count = DEFAULT; +SELECT @@global.max_write_lock_count = 4294967295; + + +--echo '#--------------------FN_DYNVARS_088_03-------------------------#' +############################################################################## +# Change the value of max_write_lock_count to a valid value for GLOBAL Scope # +############################################################################## + +SET @@global.max_write_lock_count = 1; +SELECT @@global.max_write_lock_count; +SET @@global.max_write_lock_count = 2; +SELECT @@global.max_write_lock_count; +SET @@global.max_write_lock_count = 65536; +SELECT @@global.max_write_lock_count; +SET @@global.max_write_lock_count = 4294967295; +SELECT @@global.max_write_lock_count; +SET @@global.max_write_lock_count = 4294967294; +SELECT @@global.max_write_lock_count; + + + +--echo '#------------------FN_DYNVARS_088_04-----------------------#' +################################################################ +# Change the value of max_write_lock_count to an invalid value # +################################################################ + +SET @@global.max_write_lock_count = -1024; +SELECT @@global.max_write_lock_count; +SET @@global.max_write_lock_count = 4294967296; +SELECT @@global.max_write_lock_count; +SET @@global.max_write_lock_count = -1; +SELECT @@global.max_write_lock_count; +SET @@global.max_write_lock_count = 429496729500; +SELECT @@global.max_write_lock_count; +--Error ER_PARSE_ERROR +SET @@global.max_write_lock_count = 65530.34.; +SELECT @@global.max_write_lock_count; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.max_write_lock_count = test; +SELECT @@global.max_write_lock_count; + + + +--echo '#------------------FN_DYNVARS_088_05-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.max_write_lock_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_write_lock_count'; + + +--echo '#------------------FN_DYNVARS_088_06-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.max_write_lock_count = TRUE; +SELECT @@global.max_write_lock_count; +SET @@global.max_write_lock_count = FALSE; +SELECT @@global.max_write_lock_count; + + +--echo '#---------------------FN_DYNVARS_088_07----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + +SET @@global.max_write_lock_count = 20; +SELECT @@max_write_lock_count = @@global.max_write_lock_count; + + +--echo '#---------------------FN_DYNVARS_088_08----------------------#' +############################################################################### +# Check if max_write_lock_count can be accessed with and without @@ sign # +############################################################################### + + +SET @@global.max_write_lock_count = 102; +SELECT @@max_write_lock_count; +--Error ER_UNKNOWN_TABLE +SELECT local.max_write_lock_count; +--Error ER_UNKNOWN_TABLE +SELECT global.max_write_lock_count; +--Error ER_BAD_FIELD_ERROR +SELECT max_write_lock_count = @@global.max_write_lock_count; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.max_write_lock_count = @start_global_value; +SELECT @@global.max_write_lock_count; + + +################################################### +# END OF max_write_lock_count TESTS # +################################################### + diff --git a/mysql-test/include/min_examined_row_limit_basic.inc b/mysql-test/include/min_examined_row_limit_basic.inc new file mode 100644 index 00000000000..c032d4a9d6d --- /dev/null +++ b/mysql-test/include/min_examined_row_limit_basic.inc @@ -0,0 +1,219 @@ +############## mysql-test\t\min_examined_row_limit_basic.test ############### +# # +# Variable Name: min_examined_row_limit # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 0 # +# Range:0-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable min_examined_row_limit # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +###################################################################### +# START OF min_examined_row_limit TESTS # +###################################################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.min_examined_row_limit; +SELECT @start_global_value; +SET @start_session_value = @@session.min_examined_row_limit; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_089_01-------------------------#' +###################################################################### +# Display the DEFAULT value of min_examined_row_limit # +###################################################################### + +SET @@global.min_examined_row_limit = 100; +SET @@global.min_examined_row_limit = DEFAULT; +SELECT @@global.min_examined_row_limit; + +SET @@session.min_examined_row_limit = 200; +SET @@session.min_examined_row_limit = DEFAULT; +SELECT @@session.min_examined_row_limit; + + +--echo '#--------------------FN_DYNVARS_089_02-------------------------#' +######################################################################## +# Check the DEFAULT value of min_examined_row_limit # +######################################################################## + +SET @@global.min_examined_row_limit = DEFAULT; +SELECT @@global.min_examined_row_limit = 0; + +SET @@session.min_examined_row_limit = DEFAULT; +SELECT @@session.min_examined_row_limit = 0; + + +--echo '#--------------------FN_DYNVARS_089_03-------------------------#' +################################################################################ +# Change the value of min_examined_row_limit to a valid value for GLOBAL Scope # +################################################################################ + +SET @@global.min_examined_row_limit = 0; +SELECT @@global.min_examined_row_limit; +SET @@global.min_examined_row_limit = 1; +SELECT @@global.min_examined_row_limit; +SET @@global.min_examined_row_limit = 60020; +SELECT @@global.min_examined_row_limit; +SET @@global.min_examined_row_limit = 65535; +SELECT @@global.min_examined_row_limit; +SET @@global.min_examined_row_limit = 4294967295; +SELECT @@global.min_examined_row_limit; +SET @@global.min_examined_row_limit = 4294967294; +SELECT @@global.min_examined_row_limit; + + + +--echo '#--------------------FN_DYNVARS_089_04-------------------------#' +################################################################################### +# Change the value of min_examined_row_limit to a valid value for SESSION Scope # +################################################################################### + +SET @@session.min_examined_row_limit = 0; +SELECT @@session.min_examined_row_limit; +SET @@session.min_examined_row_limit = 1; +SELECT @@session.min_examined_row_limit; +SET @@session.min_examined_row_limit = 50050; +SELECT @@session.min_examined_row_limit; +SET @@session.min_examined_row_limit = 65535; +SELECT @@session.min_examined_row_limit; +SET @@session.min_examined_row_limit = 4294967295; +SELECT @@session.min_examined_row_limit; +SET @@session.min_examined_row_limit = 4294967294; +SELECT @@session.min_examined_row_limit; + + +--echo '#------------------FN_DYNVARS_089_05-----------------------#' +#################################################################### +# Change the value of min_examined_row_limit to an invalid value # +#################################################################### + +SET @@global.min_examined_row_limit = 429496726; +SELECT @@global.min_examined_row_limit; +SET @@global.min_examined_row_limit = -1024; +SELECT @@global.min_examined_row_limit; +SET @@global.min_examined_row_limit = 429496729500; +SELECT @@global.min_examined_row_limit; +--Error ER_PARSE_ERROR +SET @@global.min_examined_row_limit = 65530.34.; +SELECT @@global.min_examined_row_limit; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.min_examined_row_limit = test; +SELECT @@global.min_examined_row_limit; + +SET @@session.min_examined_row_limit = 4294967296; +SELECT @@session.min_examined_row_limit; +SET @@session.min_examined_row_limit = -1; +SELECT @@session.min_examined_row_limit; +--Error ER_PARSE_ERROR +SET @@session.min_examined_row_limit = 65530.34.; +SET @@session.min_examined_row_limit = 4294967295021; +SELECT @@session.min_examined_row_limit; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.min_examined_row_limit = test; +SELECT @@session.min_examined_row_limit; + + +--echo '#------------------FN_DYNVARS_089_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.min_examined_row_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='min_examined_row_limit'; + +--echo '#------------------FN_DYNVARS_089_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.min_examined_row_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='min_examined_row_limit'; + + +--echo '#------------------FN_DYNVARS_089_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.min_examined_row_limit = TRUE; +SELECT @@global.min_examined_row_limit; +SET @@global.min_examined_row_limit = FALSE; +SELECT @@global.min_examined_row_limit; + + +--echo '#---------------------FN_DYNVARS_089_09----------------------#' +#################################################################################### +# Check if accessing variable with and without GLOBAL point to same variable # +#################################################################################### + +SET @@global.min_examined_row_limit = 10; +SELECT @@min_examined_row_limit = @@global.min_examined_row_limit; + + +--echo '#---------------------FN_DYNVARS_089_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@min_examined_row_limit = 100; +SELECT @@min_examined_row_limit = @@local.min_examined_row_limit; +SELECT @@local.min_examined_row_limit = @@session.min_examined_row_limit; + + +--echo '#---------------------FN_DYNVARS_089_11----------------------#' +################################################################################### +# Check if min_examined_row_limit can be accessed with and without @@ sign # +################################################################################### + +SET min_examined_row_limit = 1; +SELECT @@min_examined_row_limit; +--Error ER_UNKNOWN_TABLE +SELECT local.min_examined_row_limit; +--Error ER_UNKNOWN_TABLE +SELECT session.min_examined_row_limit; +--Error ER_BAD_FIELD_ERROR +SELECT min_examined_row_limit = @@session.min_examined_row_limit; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.min_examined_row_limit = @start_global_value; +SELECT @@global.min_examined_row_limit; +SET @@session.min_examined_row_limit = @start_session_value; +SELECT @@session.min_examined_row_limit; + + +############################################################# +# END OF min_examined_row_limit TESTS # +############################################################# + diff --git a/mysql-test/include/multi_range_count_basic.inc b/mysql-test/include/multi_range_count_basic.inc new file mode 100644 index 00000000000..47e8352196f --- /dev/null +++ b/mysql-test/include/multi_range_count_basic.inc @@ -0,0 +1,219 @@ +############## mysql-test\t\multi_range_count_basic.test ############### +# # +# Variable Name: multi_range_count # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 256 # +# Range:1-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable multi_range_count # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +################################################################# +# START OF multi_range_count TESTS # +################################################################# + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.multi_range_count; +SELECT @start_global_value; +SET @start_session_value = @@session.multi_range_count; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_090_01-------------------------#' +################################################################# +# Display the DEFAULT value of multi_range_count # +################################################################# + +SET @@global.multi_range_count = 100; +SET @@global.multi_range_count = DEFAULT; +SELECT @@global.multi_range_count; + +SET @@session.multi_range_count = 200; +SET @@session.multi_range_count = DEFAULT; +SELECT @@session.multi_range_count; + + +--echo '#--------------------FN_DYNVARS_090_02-------------------------#' +################################################################# +# Check the DEFAULT value of multi_range_count # +################################################################# + +SET @@global.multi_range_count = DEFAULT; +SELECT @@global.multi_range_count = 256; + +SET @@session.multi_range_count = DEFAULT; +SELECT @@session.multi_range_count = 256; + + +--echo '#--------------------FN_DYNVARS_090_03-------------------------#' +########################################################################### +# Change the value of multi_range_count to a valid value for GLOBAL Scope # +########################################################################### + +SET @@global.multi_range_count = 1; +SELECT @@global.multi_range_count; +SET @@global.multi_range_count = 60020; +SELECT @@global.multi_range_count; +SET @@global.multi_range_count = 65535; +SELECT @@global.multi_range_count; +SET @@global.multi_range_count = 4294967295; +SELECT @@global.multi_range_count; +SET @@global.multi_range_count = 4294967294; +SELECT @@global.multi_range_count; + + + +--echo '#--------------------FN_DYNVARS_090_04-------------------------#' +############################################################################ +# Change the value of multi_range_count to a valid value for SESSION Scope # +############################################################################ + +SET @@session.multi_range_count = 1; +SELECT @@session.multi_range_count; +SET @@session.multi_range_count = 50050; +SELECT @@session.multi_range_count; +SET @@session.multi_range_count = 65535; +SELECT @@session.multi_range_count; +SET @@session.multi_range_count = 4294967295; +SELECT @@session.multi_range_count; +SET @@session.multi_range_count = 4294967294; +SELECT @@session.multi_range_count; + + +--echo '#------------------FN_DYNVARS_090_05-----------------------#' +############################################################# +# Change the value of multi_range_count to an invalid value # +############################################################# + +SET @@global.multi_range_count = 0; +SELECT @@global.multi_range_count; +SET @@global.multi_range_count = 4294967296; +SELECT @@global.multi_range_count; +SET @@global.multi_range_count = -1024; +SELECT @@global.multi_range_count; +SET @@global.multi_range_count = 429496729500; +SELECT @@global.multi_range_count; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.multi_range_count = 65530.34; +SELECT @@global.multi_range_count; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.multi_range_count = test; +SELECT @@global.multi_range_count; + +SET @@session.multi_range_count = 0; +SELECT @@session.multi_range_count; +SET @@session.multi_range_count = 4294967296; +SELECT @@session.multi_range_count; +SET @@session.multi_range_count = -1; +SELECT @@session.multi_range_count; +--Error ER_PARSE_ERROR +SET @@session.multi_range_count = 65530.34.; +SET @@session.multi_range_count = 4294967295021; +SELECT @@session.multi_range_count; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.multi_range_count = test; +SELECT @@session.multi_range_count; + + +--echo '#------------------FN_DYNVARS_090_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.multi_range_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='multi_range_count'; + +--echo '#------------------FN_DYNVARS_090_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.multi_range_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='multi_range_count'; + + +--echo '#------------------FN_DYNVARS_090_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.multi_range_count = TRUE; +SELECT @@global.multi_range_count; +SET @@global.multi_range_count = FALSE; +SELECT @@global.multi_range_count; + + +--echo '#---------------------FN_DYNVARS_090_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + +SET @@global.multi_range_count = 10; +SELECT @@multi_range_count = @@global.multi_range_count; + + +--echo '#---------------------FN_DYNVARS_090_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@multi_range_count = 100; +SELECT @@multi_range_count = @@local.multi_range_count; +SELECT @@local.multi_range_count = @@session.multi_range_count; + + +--echo '#---------------------FN_DYNVARS_090_11----------------------#' +############################################################################ +# Check if multi_range_count can be accessed with and without @@ sign # +############################################################################ + +SET multi_range_count = 1; +SELECT @@multi_range_count; +--Error ER_UNKNOWN_TABLE +SELECT local.multi_range_count; +--Error ER_UNKNOWN_TABLE +SELECT session.multi_range_count; +--Error ER_BAD_FIELD_ERROR +SELECT multi_range_count = @@session.multi_range_count; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.multi_range_count = @start_global_value; +SELECT @@global.multi_range_count; +SET @@session.multi_range_count = @start_session_value; +SELECT @@session.multi_range_count; + + +###################################################### +# END OF multi_range_count TESTS # +###################################################### + diff --git a/mysql-test/include/myisam_max_sort_file_size_basic.inc b/mysql-test/include/myisam_max_sort_file_size_basic.inc new file mode 100644 index 00000000000..23f0607b439 --- /dev/null +++ b/mysql-test/include/myisam_max_sort_file_size_basic.inc @@ -0,0 +1,184 @@ + +############## mysql-test\t\myisam_max_sort_file_size_basic.test ################ +# # +# Variable Name: myisam_max_sort_file_size # +# Scope: GLOBAL & SESSION # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 1 # +# Range: 1 - 65536 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan Maredia # +# # +# Description: Test Cases of Dynamic System Variable myisam_max_sort_file_size # +# that checks the behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +################################################################################ + +--source include/load_sysvars.inc + +################################################################### +# START OF myisam_max_sort_file_size TESTS # +################################################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.myisam_max_sort_file_size; +SELECT @start_global_value; + +--echo '#--------------------FN_DYNVARS_094_01-------------------------#' +################################################################### +# Display the DEFAULT value of myisam_max_sort_file_size # +################################################################### + +SET @@global.myisam_max_sort_file_size = 500000; +SET @@global.myisam_max_sort_file_size = DEFAULT; +SELECT @@global.myisam_max_sort_file_size; + +--echo 'Bug# 34876: This variable has invalid default value as compared to documentation'; + +--echo '#--------------------FN_DYNVARS_094_02-------------------------#' +################################################################### +# Check the DEFAULT value of myisam_max_sort_file_size # +################################################################### + +SET @@global.myisam_max_sort_file_size = DEFAULT; +SELECT @@global.myisam_max_sort_file_size = 2147483648; + +--echo '#--------------------FN_DYNVARS_094_03-------------------------#' +################################################################################## +# Change the value of myisam_max_sort_file_size to a valid value for GLOBAL Scope # +################################################################################## + +SET @@global.myisam_max_sort_file_size = 0; +SELECT @@global.myisam_max_sort_file_size; +SET @@global.myisam_max_sort_file_size = 1024; +SELECT @@global.myisam_max_sort_file_size; +SET @@global.myisam_max_sort_file_size = 123456789; +SELECT @@global.myisam_max_sort_file_size; +SET @@global.myisam_max_sort_file_size = 2147483648*2; +SELECT @@global.myisam_max_sort_file_size; +SET @@global.myisam_max_sort_file_size = 2147483648*1024; +SELECT @@global.myisam_max_sort_file_size; +SELECT @@global.myisam_max_sort_file_size; +SET @@global.myisam_max_sort_file_size = 2147483648*2147483648; + +--echo '#--------------------FN_DYNVARS_094_04-------------------------#' +################################################################################# +# Check if variable can be access with session scope # +################################################################################# + +--Error ER_GLOBAL_VARIABLE +SET @@myisam_max_sort_file_size = 2; + +--Error ER_GLOBAL_VARIABLE +SET @@session.myisam_max_sort_file_size = 3; + +--Error ER_GLOBAL_VARIABLE +SET @@local.myisam_max_sort_file_size = 4; + + + +--echo '#------------------FN_DYNVARS_094_05-----------------------#' +#################################################################### +# Change the value of myisam_max_sort_file_size to an invalid value # +#################################################################### + +SET @@global.myisam_max_sort_file_size = -1; +SELECT @@global.myisam_max_sort_file_size; +SET @@global.myisam_max_sort_file_size = -2147483648; +SELECT @@global.myisam_max_sort_file_size; +SET @@global.myisam_max_sort_file_size = -2147483649; +SELECT @@global.myisam_max_sort_file_size; +--Error ER_PARSE_ERROR +SET @@global.myisam_max_sort_file_size = 65530.34.; +SELECT @@global.myisam_max_sort_file_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_max_sort_file_size = 2147483649.56; +SELECT @@global.myisam_max_sort_file_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_max_sort_file_size = 1G; + +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + + +--echo '#------------------FN_DYNVARS_094_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + +SET @@global.myisam_max_sort_file_size = 3000; +SELECT @@global.myisam_max_sort_file_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='myisam_max_sort_file_size'; + + +--echo '#------------------FN_DYNVARS_094_07-----------------------#' +########################################################################### +# Check if the value is present in INFORMATION_SCHEMA.SESSION_VARIABLES # +########################################################################### + +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='myisam_max_sort_file_size'; + + +--echo '#------------------FN_DYNVARS_094_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.myisam_max_sort_file_size = TRUE; +SELECT @@global.myisam_max_sort_file_size; +SET @@global.myisam_max_sort_file_size = FALSE; +SELECT @@global.myisam_max_sort_file_size; + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + + +SET @@global.myisam_max_sort_file_size = 512; +SELECT @@myisam_max_sort_file_size = @@global.myisam_max_sort_file_size; + + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +################################################################################## +# Check if myisam_max_sort_file_size can be accessed without @@ sign and scope # +################################################################################## + +--Error ER_GLOBAL_VARIABLE +SET myisam_max_sort_file_size = 2048; +--Error ER_BAD_FIELD_ERROR +SELECT myisam_max_sort_file_size; + +SELECT @@myisam_max_sort_file_size; + +#verifying another syntax for setting value# +SET global myisam_max_sort_file_size = 64; + +#################################### +# Restore initial value # +#################################### + +SET @@global.myisam_max_sort_file_size = @start_global_value; +SELECT @@global.myisam_max_sort_file_size; + +######################################################## +# END OF myisam_max_sort_file_size TESTS # +######################################################## + diff --git a/mysql-test/include/myisam_repair_threads_basic.inc b/mysql-test/include/myisam_repair_threads_basic.inc new file mode 100644 index 00000000000..8485e79ff03 --- /dev/null +++ b/mysql-test/include/myisam_repair_threads_basic.inc @@ -0,0 +1,242 @@ +############## mysql-test\t\myisam_repair_threads_basic.test ################## +# # +# Variable Name: myisam_repair_threads # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 1 # +# Range: 1-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Sharique Abdullah # +# # +# Description: Test Cases of Dynamic System Variable myisam_repair_threads # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +###################################################################### +# START OF myisam_repair_threads TESTS # +###################################################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.myisam_repair_threads; +SELECT @start_global_value; +SET @start_session_value = @@session.myisam_repair_threads; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_005_01-------------------------#' +################################################################# +# Display the DEFAULT value of myisam_block_size # +################################################################# + +SET @@global.myisam_repair_threads = 100; +SET @@global.myisam_repair_threads = DEFAULT; +SELECT @@global.myisam_repair_threads ; + +SET @@session.myisam_repair_threads = 200; +SET @@session.myisam_repair_threads = DEFAULT; +SELECT @@session.myisam_repair_threads ; + + +--echo '#--------------------FN_DYNVARS_005_02-------------------------#' +###################################################################### +# Check the DEFAULT value of myisam_repair_threads # +###################################################################### + +SET @@global.myisam_repair_threads = DEFAULT; +SELECT @@global.myisam_repair_threads = 1; + +SET @@session.myisam_repair_threads = DEFAULT; +SELECT @@session.myisam_repair_threads = 1; + + +--echo '#--------------------FN_DYNVARS_005_03-------------------------#' +############################################################################### +# Change the value of myisam_repair_threads to a valid value for GLOBAL Scope# +############################################################################### + +SET @@global.myisam_repair_threads = 1; +SELECT @@global.myisam_repair_threads ; + +SET @@global.myisam_repair_threads = 4294967295; +SELECT @@global.myisam_repair_threads ; + +SET @@global.myisam_repair_threads = 655354; +SELECT @@global.myisam_repair_threads ; + + +--echo '#--------------------FN_DYNVARS_005_04-------------------------#' +############################################################################### +# Change the value of myisam_repair_threads to a valid value for SESSION +# Scope +############################################################################### + +SET @@session.myisam_repair_threads = 1; +SELECT @@session.myisam_repair_threads ; + +SET @@session.myisam_repair_threads = 4294967295; +SELECT @@session.myisam_repair_threads ; + +SET @@session.myisam_repair_threads = 655345; +SELECT @@session.myisam_repair_threads ; + + + + +--echo '#------------------FN_DYNVARS_005_05-----------------------#' +################################################################## +# Change the value of myisam_repair_threads to an invalid value # +################################################################## + +SET @@global.myisam_repair_threads = 0; +SELECT @@global.myisam_repair_threads ; + +SET @@global.myisam_repair_threads = -1024; +SELECT @@global.myisam_repair_threads ; + +SET @@global.myisam_repair_threads = 429496729533; +SELECT @@global.myisam_repair_threads ; + + +--Error ER_PARSE_ERROR +SET @@global.myisam_repair_threads = 65530.34.; +SELECT @@global.myisam_repair_threads ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_repair_threads = test; +SELECT @@global.myisam_repair_threads ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_repair_threads = "test"; +SELECT @@global.myisam_repair_threads ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_repair_threads = 'test'; +SELECT @@global.myisam_repair_threads ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_repair_threads = ON; +SELECT @@global.myisam_repair_threads ; + + +SET @@session.myisam_repair_threads = 0; +SELECT @@session.myisam_repair_threads ; + +SET @@session.myisam_repair_threads = -2; +SELECT @@session.myisam_repair_threads ; + +--Error ER_PARSE_ERROR + +SET @@session.myisam_repair_threads = 65530.34.; +SELECT @@session.myisam_repair_threads ; + + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.myisam_repair_threads = test; +SELECT @@session.myisam_repair_threads ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.myisam_repair_threads = "test"; +SELECT @@session.myisam_repair_threads ; + + +--echo '#------------------FN_DYNVARS_005_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.myisam_repair_threads = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='myisam_repair_threads '; + +--echo '#------------------FN_DYNVARS_005_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.myisam_repair_threads = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='myisam_repair_threads '; + + +--echo '#------------------FN_DYNVARS_005_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.myisam_repair_threads = TRUE; +SELECT @@global.myisam_repair_threads ; +SET @@global.myisam_repair_threads = FALSE; +SELECT @@global.myisam_repair_threads ; + + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +############################################################################### +# Check if accessing variable with and without GLOBAL point to same variable # +############################################################################### + +SET @@global.myisam_repair_threads = 10; +SELECT @@myisam_repair_threads = @@global.myisam_repair_threads ; + + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to +# same session variable # +######################################################################################################## + +SET @@myisam_repair_threads = 100; +SELECT @@myisam_repair_threads = @@local.myisam_repair_threads ; +SELECT @@local.myisam_repair_threads = @@session.myisam_repair_threads ; + + +--echo '#---------------------FN_DYNVARS_001_11----------------------#' +################################################################################### +# Check if myisam_repair_threads can be accessed with and without @@ sign # +################################################################################### + +SET myisam_repair_threads = 1; +SELECT @@myisam_repair_threads ; +--Error ER_UNKNOWN_TABLE + +SELECT local.myisam_repair_threads ; + +--Error ER_UNKNOWN_TABLE +SELECT session.myisam_repair_threads ; + +--Error ER_BAD_FIELD_ERROR +SELECT myisam_repair_threads = @@session.myisam_repair_threads ; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.myisam_repair_threads = @start_global_value; +SELECT @@global.myisam_repair_threads ; +SET @@session.myisam_repair_threads = @start_session_value; +SELECT @@session.myisam_repair_threads ; + + +############################################################# +# END OF myisam_repair_threads TESTS # +############################################################# + diff --git a/mysql-test/include/myisam_sort_buffer_size_basic.inc b/mysql-test/include/myisam_sort_buffer_size_basic.inc new file mode 100644 index 00000000000..8e36d8a2c70 --- /dev/null +++ b/mysql-test/include/myisam_sort_buffer_size_basic.inc @@ -0,0 +1,240 @@ +############## mysql-test\t\myisam_sort_buffer_size_basic.test ############### +# # +# Variable Name: myisam_sort_buffer_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: # +# Range: # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan # +# # +# Description: Test Cases of Dynamic System Variable myisam_sort_buffer_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +######################################################################## +# START OF myisam_sort_buffer_size TESTS # +######################################################################## + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.myisam_sort_buffer_size ; +SELECT @start_global_value; +SET @start_session_value = @@session.myisam_sort_buffer_size ; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_005_01-------------------------#' +######################################################################## +# Display the DEFAULT value of myisam_block_size # +######################################################################## + +SET @@global.myisam_sort_buffer_size = 100; +SET @@global.myisam_sort_buffer_size = DEFAULT; +SELECT @@global.myisam_sort_buffer_size ; + +SET @@session.myisam_sort_buffer_size = 200; +SET @@session.myisam_sort_buffer_size = DEFAULT; +SELECT @@session.myisam_sort_buffer_size ; + + +--echo '#--------------------FN_DYNVARS_005_02-------------------------#' +######################################################################## +# Check the DEFAULT value of myisam_sort_buffer_size # +######################################################################## + +SET @@global.myisam_sort_buffer_size = DEFAULT; +SELECT @@global.myisam_sort_buffer_size = 8388608; + +SET @@session.myisam_sort_buffer_size = DEFAULT; +SELECT @@session.myisam_sort_buffer_size = 8388608; + + +--echo '#--------------------FN_DYNVARS_005_03-------------------------#' +################################################################################## +# Change the value of myisam_sort_buffer_size to a valid value for GLOBAL Scope # +################################################################################## + +SET @@global.myisam_sort_buffer_size = 4; +SELECT @@global.myisam_sort_buffer_size ; + +SET @@global.myisam_sort_buffer_size = 4294967295; +SELECT @@global.myisam_sort_buffer_size ; + +SET @@global.myisam_sort_buffer_size = 655354; +SELECT @@global.myisam_sort_buffer_size ; + + +--echo '#--------------------FN_DYNVARS_005_04-------------------------#' +################################################################################### +# Change the value of myisam_sort_buffer_size to a valid value for SESSION Scope # +################################################################################### + +SET @@session.myisam_sort_buffer_size = 4; +SELECT @@session.myisam_sort_buffer_size ; + +SET @@session.myisam_sort_buffer_size = 4294967295; +SELECT @@session.myisam_sort_buffer_size ; + +SET @@session.myisam_sort_buffer_size = 655345; +SELECT @@session.myisam_sort_buffer_size ; + + + + +--echo '#------------------FN_DYNVARS_005_05-----------------------#' +#################################################################### +# Change the value of myisam_sort_buffer_size to an invalid value # +#################################################################### + +SET @@global.myisam_sort_buffer_size = 0; +SELECT @@global.myisam_sort_buffer_size ; + +SET @@global.myisam_sort_buffer_size = -1024; +SELECT @@global.myisam_sort_buffer_size ; + +SET @@global.myisam_sort_buffer_size = 429496729533; +SELECT @@global.myisam_sort_buffer_size ; + + +--Error ER_PARSE_ERROR +SET @@global.myisam_sort_buffer_size = 65530.34.; +SELECT @@global.myisam_sort_buffer_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_sort_buffer_size = test; +SELECT @@global.myisam_sort_buffer_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_sort_buffer_size = "test"; +SELECT @@global.myisam_sort_buffer_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_sort_buffer_size = 'test'; +SELECT @@global.myisam_sort_buffer_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.myisam_sort_buffer_size = ON; +SELECT @@global.myisam_sort_buffer_size ; + + +SET @@session.myisam_sort_buffer_size = 0; +SELECT @@session.myisam_sort_buffer_size ; + +SET @@session.myisam_sort_buffer_size = -2; +SELECT @@session.myisam_sort_buffer_size ; + +--Error ER_PARSE_ERROR + +SET @@session.myisam_sort_buffer_size = 65530.34.; +SELECT @@session.myisam_sort_buffer_size ; + + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.myisam_sort_buffer_size = test; +SELECT @@session.myisam_sort_buffer_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.myisam_sort_buffer_size = "test"; +SELECT @@session.myisam_sort_buffer_size ; + + +--echo '#------------------FN_DYNVARS_005_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.myisam_sort_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='myisam_sort_buffer_size '; + +--echo '#------------------FN_DYNVARS_005_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.myisam_sort_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='myisam_sort_buffer_size '; + + +--echo '#------------------FN_DYNVARS_005_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.myisam_sort_buffer_size = TRUE; +SELECT @@global.myisam_sort_buffer_size ; +SET @@global.myisam_sort_buffer_size = FALSE; +SELECT @@global.myisam_sort_buffer_size ; + + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +#################################################################################### +# Check if accessing variable with and without GLOBAL point to same variable # +#################################################################################### + +SET @@global.myisam_sort_buffer_size = 10; +SELECT @@myisam_sort_buffer_size = @@global.myisam_sort_buffer_size ; + + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@myisam_sort_buffer_size = 100; +SELECT @@myisam_sort_buffer_size = @@local.myisam_sort_buffer_size ; +SELECT @@local.myisam_sort_buffer_size = @@session.myisam_sort_buffer_size ; + + +--echo '#---------------------FN_DYNVARS_001_11----------------------#' +################################################################################### +# Check if myisam_sort_buffer_size can be accessed with and without @@ sign # +################################################################################### + +SET myisam_sort_buffer_size = 1; +SELECT @@myisam_sort_buffer_size ; +--Error ER_UNKNOWN_TABLE + +SELECT local.myisam_sort_buffer_size ; + +--Error ER_UNKNOWN_TABLE +SELECT session.myisam_sort_buffer_size ; + +--Error ER_BAD_FIELD_ERROR +SELECT myisam_sort_buffer_size = @@session.myisam_sort_buffer_size ; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.myisam_sort_buffer_size = @start_global_value; +SELECT @@global.myisam_sort_buffer_size ; +SET @@session.myisam_sort_buffer_size = @start_session_value; +SELECT @@session.myisam_sort_buffer_size ; + + +############################################################# +# END OF myisam_sort_buffer_size TESTS # +############################################################# + diff --git a/mysql-test/include/net_retry_count_basic.inc b/mysql-test/include/net_retry_count_basic.inc new file mode 100644 index 00000000000..537d8eea6c6 --- /dev/null +++ b/mysql-test/include/net_retry_count_basic.inc @@ -0,0 +1,217 @@ +############## mysql-test\t\net_retry_count_basic.test ############### +# # +# Variable Name: net_retry_count # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value:10 # +# Range: 1-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable net_retry_count # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +############################################################### +# START OF net_retry_count TESTS # +############################################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.net_retry_count; +SELECT @start_global_value; +SET @start_session_value = @@session.net_retry_count; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_111_01-------------------------#' +############################################################### +# Display the DEFAULT value of net_retry_count # +############################################################### + +SET @@global.net_retry_count = 100; +SET @@global.net_retry_count = DEFAULT; +SELECT @@global.net_retry_count; + +SET @@session.net_retry_count = 200; +SET @@session.net_retry_count = DEFAULT; +SELECT @@session.net_retry_count; + + +--echo '#--------------------FN_DYNVARS_111_02-------------------------#' +############################################################### +# Check the DEFAULT value of net_retry_count # +############################################################### + +SET @@global.net_retry_count = DEFAULT; +SELECT @@global.net_retry_count = 10; + +SET @@session.net_retry_count = DEFAULT; +SELECT @@session.net_retry_count = 10; + + +--echo '#--------------------FN_DYNVARS_111_03-------------------------#' +######################################################################### +# Change the value of net_retry_count to a valid value for GLOBAL Scope # +######################################################################### + +SET @@global.net_retry_count = 1; +SELECT @@global.net_retry_count; +SET @@global.net_retry_count = 2; +SELECT @@global.net_retry_count; +SET @@global.net_retry_count = 4294967295; +SELECT @@global.net_retry_count; +SET @@global.net_retry_count = 4294967294; +SELECT @@global.net_retry_count; +SET @@global.net_retry_count = 65536; +SELECT @@global.net_retry_count; + +--echo '#--------------------FN_DYNVARS_111_04-------------------------#' +########################################################################## +# Change the value of net_retry_count to a valid value for SESSION Scope # +########################################################################## + +SET @@session.net_retry_count = 1; +SELECT @@session.net_retry_count; +SET @@session.net_retry_count = 2; +SELECT @@session.net_retry_count; +SET @@session.net_retry_count = 65535; +SELECT @@session.net_retry_count; +SET @@session.net_retry_count = 4294967295; +SELECT @@session.net_retry_count; +SET @@session.net_retry_count = 4294967294; +SELECT @@session.net_retry_count; + +--echo '#------------------FN_DYNVARS_111_05-----------------------#' +########################################################### +# Change the value of net_retry_count to an invalid value # +########################################################### + +SET @@global.net_retry_count = 0; +SELECT @@global.net_retry_count; +SET @@global.net_retry_count = -1024; +SELECT @@global.net_retry_count; +SET @@global.net_retry_count = 4294967296; +SELECT @@global.net_retry_count; +SET @@global.net_retry_count = 429496729500; +SELECT @@global.net_retry_count; +--Error ER_PARSE_ERROR +SET @@global.net_retry_count = 65530.34.; +SELECT @@global.net_retry_count; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.net_retry_count = test; +SELECT @@global.net_retry_count; + +SET @@session.net_retry_count = 0; +SELECT @@session.net_retry_count; +SET @@session.net_retry_count = -2; +SELECT @@session.net_retry_count; +--Error ER_PARSE_ERROR +SET @@session.net_retry_count = 65530.34.; +SET @@session.net_retry_count = 6555015425; +SELECT @@session.net_retry_count; +SET @@session.net_retry_count = 4294967296; +SELECT @@session.net_retry_count; + +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.net_retry_count = test; +SELECT @@session.net_retry_count; + + +--echo '#------------------FN_DYNVARS_111_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.net_retry_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='net_retry_count'; + +--echo '#------------------FN_DYNVARS_111_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.net_retry_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='net_retry_count'; + + +--echo '#------------------FN_DYNVARS_111_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.net_retry_count = TRUE; +SELECT @@global.net_retry_count; +SET @@global.net_retry_count = FALSE; +SELECT @@global.net_retry_count; + + +--echo '#---------------------FN_DYNVARS_111_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + +SET @@global.net_retry_count = 10; +SELECT @@net_retry_count = @@global.net_retry_count; + + +--echo '#---------------------FN_DYNVARS_111_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@net_retry_count = 100; +SELECT @@net_retry_count = @@local.net_retry_count; +SELECT @@local.net_retry_count = @@session.net_retry_count; + + +--echo '#---------------------FN_DYNVARS_111_11----------------------#' +########################################################################## +# Check if net_retry_count can be accessed with and without @@ sign # +########################################################################## + +SET net_retry_count = 1; +SELECT @@net_retry_count; +--Error ER_UNKNOWN_TABLE +SELECT local.net_retry_count; +--Error ER_UNKNOWN_TABLE +SELECT session.net_retry_count; +--Error ER_BAD_FIELD_ERROR +SELECT net_retry_count = @@session.net_retry_count; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.net_retry_count = @start_global_value; +SELECT @@global.net_retry_count; +SET @@session.net_retry_count = @start_session_value; +SELECT @@session.net_retry_count; + + +#################################################### +# END OF net_retry_count TESTS # +#################################################### + diff --git a/mysql-test/include/query_alloc_block_size_basic.inc b/mysql-test/include/query_alloc_block_size_basic.inc new file mode 100644 index 00000000000..208fe6b3da4 --- /dev/null +++ b/mysql-test/include/query_alloc_block_size_basic.inc @@ -0,0 +1,225 @@ +############## mysql-test\t\query_alloc_block_size_basic.test ############### +# # +# Variable Name: query_alloc_block_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 8192 # +# Range: 1024-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable query_alloc_block_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +################################################################### +# START OF query_alloc_block_size TESTS # +################################################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.query_alloc_block_size; +SELECT @start_global_value; +SET @start_session_value = @@session.query_alloc_block_size; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_130_01-------------------------#' +################################################################### +# Display the DEFAULT value of query_alloc_block_size # +################################################################### + +SET @@global.query_alloc_block_size = 10000; +SET @@global.query_alloc_block_size = DEFAULT; +SELECT @@global.query_alloc_block_size; + +SET @@session.query_alloc_block_size = 20000; +SET @@session.query_alloc_block_size = DEFAULT; +SELECT @@session.query_alloc_block_size; + + +--echo '#--------------------FN_DYNVARS_130_02-------------------------#' +################################################################### +# Check the DEFAULT value of query_alloc_block_size # +################################################################### + +SET @@global.query_alloc_block_size = DEFAULT; +SELECT @@global.query_alloc_block_size = 8192; + +SET @@session.query_alloc_block_size = DEFAULT; +SELECT @@session.query_alloc_block_size = 8192; + + +--echo '#--------------------FN_DYNVARS_130_03-------------------------#' +############################################################################# +# Change the value of query_alloc_block_size to a valid value for GLOBAL Scope # +############################################################################# + +SET @@global.query_alloc_block_size = 1024; +SELECT @@global.query_alloc_block_size; +SET @@global.query_alloc_block_size = 1025; +SELECT @@global.query_alloc_block_size; +SET @@global.query_alloc_block_size = 4294967295; +SELECT @@global.query_alloc_block_size; +SET @@global.query_alloc_block_size = 4294967294; +SELECT @@global.query_alloc_block_size; +SET @@global.query_alloc_block_size = 65536; +SELECT @@global.query_alloc_block_size; + +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + + +--echo '#--------------------FN_DYNVARS_130_04-------------------------#' +################################################################################# +# Change the value of query_alloc_block_size to a valid value for SESSION Scope # +################################################################################# + +SET @@session.query_alloc_block_size = 1024; +SELECT @@session.query_alloc_block_size; +SET @@session.query_alloc_block_size = 1025; +SELECT @@session.query_alloc_block_size; +SET @@session.query_alloc_block_size = 4294967295; +SELECT @@session.query_alloc_block_size; +SET @@session.query_alloc_block_size = 4294967294; +SELECT @@session.query_alloc_block_size; +SET @@session.query_alloc_block_size = 655536; +SELECT @@session.query_alloc_block_size; + +--echo '#------------------FN_DYNVARS_130_05-----------------------#' +################################################################## +# Change the value of query_alloc_block_size to an invalid value # +################################################################## + +SET @@global.query_alloc_block_size = 64; +SELECT @@global.query_alloc_block_size; +SET @@global.query_alloc_block_size = -1; +SELECT @@global.query_alloc_block_size; +SET @@global.query_alloc_block_size = 1023; +SELECT @@global.query_alloc_block_size; +SET @@global.query_alloc_block_size = 4294967296; +SELECT @@global.query_alloc_block_size; +--Error ER_PARSE_ERROR +SET @@global.query_alloc_block_size = 65530.34.; +SELECT @@global.query_alloc_block_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_alloc_block_size = test; +SELECT @@global.query_alloc_block_size; + +SET @@session.query_alloc_block_size = 64; +SELECT @@session.query_alloc_block_size; +SET @@session.query_alloc_block_size = -2; +SELECT @@session.query_alloc_block_size; +--Error ER_PARSE_ERROR +SET @@session.query_alloc_block_size = 65530.34.; +SET @@session.query_alloc_block_size = 1023; +SELECT @@session.query_alloc_block_size; +SET @@session.query_alloc_block_size = 4294967296; +SELECT @@session.query_alloc_block_size; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.query_alloc_block_size = test; +SELECT @@session.query_alloc_block_size; + +--echo '#------------------FN_DYNVARS_130_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + +#SET @@global.query_alloc_block_size = 1; +#SET @@session.query_alloc_block_size = 12; +--echo 'Bug# 34877: OutOFMemeory errors are coming if we dont assign these values to variable before comparision statement'; + +SET @@global.query_alloc_block_size = 1; +SET @@session.query_alloc_block_size = 12; + +SELECT @@global.query_alloc_block_size = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_alloc_block_size'; + + +--echo '#------------------FN_DYNVARS_130_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.query_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_alloc_block_size'; + + +--echo '#------------------FN_DYNVARS_130_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.query_alloc_block_size = TRUE; +SELECT @@global.query_alloc_block_size; +SET @@global.query_alloc_block_size = FALSE; +SELECT @@global.query_alloc_block_size; + + +--echo '#---------------------FN_DYNVARS_130_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + +SET @@global.query_alloc_block_size = 2048; +SELECT @@query_alloc_block_size = @@global.query_alloc_block_size; + + +--echo '#---------------------FN_DYNVARS_130_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@query_alloc_block_size = 5000; +SELECT @@query_alloc_block_size = @@local.query_alloc_block_size; +SELECT @@local.query_alloc_block_size = @@session.query_alloc_block_size; + + +--echo '#---------------------FN_DYNVARS_130_11----------------------#' +############################################################################## +# Check if query_alloc_block_size can be accessed with and without @@ sign # +############################################################################## + +SET query_alloc_block_size = 1024; +SELECT @@query_alloc_block_size; +--Error ER_UNKNOWN_TABLE +SELECT local.query_alloc_block_size; +--Error ER_UNKNOWN_TABLE +SELECT session.query_alloc_block_size; +--Error ER_BAD_FIELD_ERROR +SELECT query_alloc_block_size = @@session.query_alloc_block_size; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.query_alloc_block_size = @start_global_value; +SELECT @@global.query_alloc_block_size; +SET @@session.query_alloc_block_size = @start_session_value; +SELECT @@session.query_alloc_block_size; + + +######################################################## +# END OF query_alloc_block_size TESTS # +######################################################## + diff --git a/mysql-test/include/query_cache_limit_basic.inc b/mysql-test/include/query_cache_limit_basic.inc new file mode 100644 index 00000000000..2eb4a597eef --- /dev/null +++ b/mysql-test/include/query_cache_limit_basic.inc @@ -0,0 +1,178 @@ +############## mysql-test\t\query_cache_limit_basic.test ############### +# # +# Variable Name: query_cache_limit # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 1048576 # +# Min value: 0 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable query_cache_limit # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/have_query_cache.inc +--source include/load_sysvars.inc + +######################################################################## +# START OF query_cache_limit TESTS # +######################################################################## + + +######################################################################## +# Saving initial value of query_cache_limit in a temporary variable # +######################################################################## + +SET @start_value = @@global.query_cache_limit; +SELECT @start_value; + + +--echo '#--------------------FN_DYNVARS_131_01------------------------#' +######################################################################## +# Display the DEFAULT value of query_cache_limit # +######################################################################## + +SET @@global.query_cache_limit = 99; +SET @@global.query_cache_limit = DEFAULT; +SELECT @@global.query_cache_limit; + + +--echo '#---------------------FN_DYNVARS_131_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.query_cache_limit = @start_value; +SELECT @@global.query_cache_limit = 1048576; + + +--echo '#--------------------FN_DYNVARS_131_03------------------------#' +######################################################################## +# Change the value of query_cache_limit to a valid value # +######################################################################## + +SET @@global.query_cache_limit = 0; +SELECT @@global.query_cache_limit; +SET @@global.query_cache_limit = 1; +SELECT @@global.query_cache_limit; +SET @@global.query_cache_limit = 1048576; +SELECT @@global.query_cache_limit; +SET @@global.query_cache_limit = 1048575; +SELECT @@global.query_cache_limit; + + +--echo '#--------------------FN_DYNVARS_131_04-------------------------#' +########################################################################### +# Change the value of query_cache_limit to invalid value # +########################################################################### + +SET @@global.query_cache_limit = -1; +SELECT @@global.query_cache_limit; +SET @@global.query_cache_limit = 4294967296; +SELECT @@global.query_cache_limit; +SET @@global.query_cache_limit = 10240022115; +SELECT @@global.query_cache_limit; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_cache_limit = 10000.01; +SELECT @@global.query_cache_limit; +SET @@global.query_cache_limit = -1024; +SELECT @@global.query_cache_limit; +SET @@global.query_cache_limit = 42949672950; +SELECT @@global.query_cache_limit; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_cache_limit = ON; +SELECT @@global.query_cache_limit; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_cache_limit = 'test'; +SELECT @@global.query_cache_limit; + + +--echo '#-------------------FN_DYNVARS_131_05----------------------------#' +########################################################################### +# Test if accessing session query_cache_limit gives error # +########################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.query_cache_limit = 0; +SELECT @@query_cache_limit; + + +--echo '#----------------------FN_DYNVARS_131_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.query_cache_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_cache_limit'; + +SELECT @@query_cache_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_cache_limit'; + + +--echo '#---------------------FN_DYNVARS_131_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.query_cache_limit = TRUE; +SELECT @@global.query_cache_limit; +SET @@global.query_cache_limit = FALSE; +SELECT @@global.query_cache_limit; + + +--echo '#---------------------FN_DYNVARS_131_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.query_cache_limit = 1; +SELECT @@query_cache_limit = @@global.query_cache_limit; + + +--echo '#---------------------FN_DYNVARS_131_09----------------------#' +########################################################################## +# Check if query_cache_limit can be accessed with and without @@ sign # +########################################################################## + +--Error ER_GLOBAL_VARIABLE +SET query_cache_limit = 1; +SELECT @@query_cache_limit; +--Error ER_PARSE_ERROR +SET local.query_cache_limit = 1; +--Error ER_UNKNOWN_TABLE +SELECT local.query_cache_limit; +--Error ER_PARSE_ERROR +SET global.query_cache_limit = 1; +--Error ER_UNKNOWN_TABLE +SELECT global.query_cache_limit; +--Error ER_BAD_FIELD_ERROR +SELECT query_cache_limit = @@session.query_cache_limit; + + +############################## +# Restore initial value # +############################## + +SET @@global.query_cache_limit = @start_value; +SELECT @@global.query_cache_limit; + + +######################################################################## +# END OF query_cache_limit TESTS # +######################################################################## diff --git a/mysql-test/include/query_cache_min_res_unit_basic.inc b/mysql-test/include/query_cache_min_res_unit_basic.inc new file mode 100644 index 00000000000..1b65e035b18 --- /dev/null +++ b/mysql-test/include/query_cache_min_res_unit_basic.inc @@ -0,0 +1,187 @@ +############## mysql-test\t\query_cache_min_res_unit_basic.test ############### +# # +# Variable Name: query_cache_min_res_unit # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value:1024 # +# Min Value:0 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman Rawala # +# # +# Description: Test Cases of Dynamic System Variable query_cache_min_res_unit # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/have_query_cache.inc +--source include/load_sysvars.inc + +######################################################################## + + +######################################################################## +# START OF query_cache_min_res_unit TESTS # +######################################################################## + + +############################################################################### +# Saving initial value of query_cache_min_res_unit in a temporary variable # +############################################################################### + +SET @start_value = @@global.query_cache_min_res_unit; +SELECT @start_value; + + +--echo '#--------------------FN_DYNVARS_132_01------------------------#' +############################################################################### +# Display the DEFAULT value of query_cache_min_res_unit # +############################################################################### + +SET @@global.query_cache_min_res_unit = 99; +SET @@global.query_cache_min_res_unit = DEFAULT; +SELECT @@global.query_cache_min_res_unit; + + +--echo '#---------------------FN_DYNVARS_132_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.query_cache_min_res_unit = @start_value; +SELECT @@global.query_cache_min_res_unit = 4096; + + +--echo '#--------------------FN_DYNVARS_132_03------------------------#' +################################################################################ +# Change the value of query_cache_min_res_unit to a valid value # +################################################################################ + +SET @@global.query_cache_min_res_unit = 0; +SELECT @@global.query_cache_min_res_unit; +SET @@global.query_cache_min_res_unit = 1; +SELECT @@global.query_cache_min_res_unit; +--echo 'Bug#34842: FN_DYNVARS_132_03 - Minimum value according to documentation is 0, and here it is 512'; +SET @@global.query_cache_min_res_unit = 512; +SELECT @@global.query_cache_min_res_unit; +SET @@global.query_cache_min_res_unit = 513; +SELECT @@global.query_cache_min_res_unit; +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.query_cache_min_res_unit = 1048576; +SELECT @@global.query_cache_min_res_unit; +SET @@global.query_cache_min_res_unit = 1048575; +SELECT @@global.query_cache_min_res_unit; + + +--echo '#--------------------FN_DYNVARS_132_04-------------------------#' +################################################################################### +# Change the value of query_cache_min_res_unit to invalid value # +################################################################################### + +SET @@global.query_cache_min_res_unit = -1; +SELECT @@global.query_cache_min_res_unit; +SET @@global.query_cache_min_res_unit = 4294967296; +SELECT @@global.query_cache_min_res_unit; +SET @@global.query_cache_min_res_unit = 511; +SELECT @@global.query_cache_min_res_unit; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_cache_min_res_unit = 10000.01; +SELECT @@global.query_cache_min_res_unit; +SET @@global.query_cache_min_res_unit = -1024; +SELECT @@global.query_cache_min_res_unit; +SET @@global.query_cache_min_res_unit = 42949672950; +SELECT @@global.query_cache_min_res_unit; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_cache_min_res_unit = ON; +SELECT @@global.query_cache_min_res_unit; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_cache_min_res_unit = 'test'; +SELECT @@global.query_cache_min_res_unit; + + +--echo '#-------------------FN_DYNVARS_132_05----------------------------#' +################################################################################### +# Test if accessing session query_cache_min_res_unit gives error # +################################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.query_cache_min_res_unit = 0; +SELECT @@query_cache_min_res_unit; + + +--echo '#----------------------FN_DYNVARS_132_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.query_cache_min_res_unit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_cache_min_res_unit'; + +SELECT @@query_cache_min_res_unit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_cache_min_res_unit'; + + +--echo '#---------------------FN_DYNVARS_132_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.query_cache_min_res_unit = TRUE; +SELECT @@global.query_cache_min_res_unit; +SET @@global.query_cache_min_res_unit = FALSE; +SELECT @@global.query_cache_min_res_unit; + + +--echo '#---------------------FN_DYNVARS_132_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.query_cache_min_res_unit = 1; +SELECT @@query_cache_min_res_unit = @@global.query_cache_min_res_unit; + + +--echo '#---------------------FN_DYNVARS_132_09----------------------#' +################################################################################## +# Check if query_cache_min_res_unit can be accessed with and without @@ sign # +################################################################################## + +--Error ER_GLOBAL_VARIABLE +SET query_cache_min_res_unit = 1; +SELECT @@query_cache_min_res_unit; +--Error ER_PARSE_ERROR +SET local.query_cache_min_res_unit = 1; +--Error ER_UNKNOWN_TABLE +SELECT local.query_cache_min_res_unit; +--Error ER_PARSE_ERROR +SET global.query_cache_min_res_unit = 1; +--Error ER_UNKNOWN_TABLE +SELECT global.query_cache_min_res_unit; +--Error ER_BAD_FIELD_ERROR +SELECT query_cache_min_res_unit = @@session.query_cache_min_res_unit; + + +############################## +# Restore initial value # +############################## + +SET @@global.query_cache_min_res_unit = @start_value; +SELECT @@global.query_cache_min_res_unit; + + +######################################################################## +# END OF query_cache_min_res_unit TESTS # +######################################################################## diff --git a/mysql-test/include/query_cache_size_basic.inc b/mysql-test/include/query_cache_size_basic.inc new file mode 100644 index 00000000000..1a3f9e1efe2 --- /dev/null +++ b/mysql-test/include/query_cache_size_basic.inc @@ -0,0 +1,175 @@ +############## mysql-test\t\query_cache_size_basic.test ############### +# # +# Variable Name: query_cache_size # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 0 # +# Range: - # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable query_cache_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/have_query_cache.inc +--source include/load_sysvars.inc + +######################################################################## +# START OF query_cache_size TESTS # +######################################################################## + + +############################################################################### +# Saving initial value of query_cache_size in a temporary variable # +############################################################################### + +SET @start_value = @@global.query_cache_size; +SELECT @start_value; + +--echo '#--------------------FN_DYNVARS_133_01------------------------#' +############################################################################### +# Display the DEFAULT value of query_cache_size # +############################################################################### + +SET @@global.query_cache_size = 99; +SET @@global.query_cache_size = DEFAULT; +SELECT @@global.query_cache_size; + +--echo '#---------------------FN_DYNVARS_133_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.query_cache_size = @start_value; +SELECT @@global.query_cache_size = 0; + +--echo '#--------------------FN_DYNVARS_133_03------------------------#' +################################################################################ +# Change the value of query_cache_size to a valid value # +################################################################################ + +SET @@global.query_cache_size = 0; +SELECT @@global.query_cache_size; +SET @@global.query_cache_size = 1; +SELECT @@global.query_cache_size; + +SET @@global.query_cache_size = 512; +SELECT @@global.query_cache_size; +SET @@global.query_cache_size = 1024; +SELECT @@global.query_cache_size; +--echo : 'Bug#34880: Warnings are coming on assinging valid values to variable +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.query_cache_size = 1048576; +SELECT @@global.query_cache_size; +SET @@global.query_cache_size = 1048575; +SELECT @@global.query_cache_size; + +--echo '#--------------------FN_DYNVARS_133_04-------------------------#' +################################################################################### +# Change the value of query_cache_size to invalid value # +################################################################################### + +SET @@global.query_cache_size = -1; +SELECT @@global.query_cache_size; +SET @@global.query_cache_size = 4294967296; +SELECT @@global.query_cache_size; +SET @@global.query_cache_size = 511; +SELECT @@global.query_cache_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_cache_size = 10000.01; +SELECT @@global.query_cache_size; +SET @@global.query_cache_size = -1024; +SELECT @@global.query_cache_size; +SET @@global.query_cache_size = 42949672950; +SELECT @@global.query_cache_size; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_cache_size = ON; +SELECT @@global.query_cache_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_cache_size = 'test'; +SELECT @@global.query_cache_size; + +--echo '#-------------------FN_DYNVARS_133_05----------------------------#' +################################################################################### +# Test if accessing session query_cache_size gives error # +################################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.query_cache_size = 0; +SELECT @@query_cache_size; + +--echo '#----------------------FN_DYNVARS_133_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.query_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_cache_size'; + +SELECT @@query_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_cache_size'; + +--echo '#---------------------FN_DYNVARS_133_07----------------------#' +################################################################### +# Check if TRUE and FALSE values can be used on variable # +################################################################### + +SET @@global.query_cache_size = TRUE; +SELECT @@global.query_cache_size; +SET @@global.query_cache_size = FALSE; +SELECT @@global.query_cache_size; + +--echo '#---------------------FN_DYNVARS_133_08----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@global.query_cache_size = 1; +SELECT @@query_cache_size = @@global.query_cache_size; + +--echo '#---------------------FN_DYNVARS_133_09----------------------#' +################################################################################## +# Check if query_cache_size can be accessed with and without @@ sign # +################################################################################## + +--Error ER_GLOBAL_VARIABLE +SET query_cache_size = 1; +SELECT @@query_cache_size; +--Error ER_PARSE_ERROR +SET local.query_cache_size = 1; +--Error ER_UNKNOWN_TABLE +SELECT local.query_cache_size; +--Error ER_PARSE_ERROR +SET global.query_cache_size = 1; +--Error ER_UNKNOWN_TABLE +SELECT global.query_cache_size; +--Error ER_BAD_FIELD_ERROR +SELECT query_cache_size = @@session.query_cache_size; + +############################## +# Restore initial value # +############################## + +SET @@global.query_cache_size = @start_value; +SELECT @@global.query_cache_size; + +######################################################################## +# END OF query_cache_size TESTS # +######################################################################## + diff --git a/mysql-test/include/query_prealloc_size_basic.inc b/mysql-test/include/query_prealloc_size_basic.inc new file mode 100644 index 00000000000..1793d1874af --- /dev/null +++ b/mysql-test/include/query_prealloc_size_basic.inc @@ -0,0 +1,239 @@ +############## mysql-test\t\query_prealloc_size_basic.test ############### +# # +# Variable Name: query_prealloc_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 8192 # +# Range: 8192-4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan # +# # +# Description: Test Cases of Dynamic System Variable query_prealloc_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +######################################################################## +# START OF query_prealloc_size TESTS # +######################################################################## + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.query_prealloc_size ; +SELECT @start_global_value; +SET @start_session_value = @@session.query_prealloc_size ; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_005_01-------------------------#' +######################################################################## +# Display the DEFAULT value of myisam_block_size # +######################################################################## + +SET @@global.query_prealloc_size = 100; +SET @@global.query_prealloc_size = DEFAULT; +SELECT @@global.query_prealloc_size ; + +SET @@session.query_prealloc_size = 200; +SET @@session.query_prealloc_size = DEFAULT; +SELECT @@session.query_prealloc_size ; + + +--echo '#--------------------FN_DYNVARS_005_02-------------------------#' +######################################################################## +# Check the DEFAULT value of query_prealloc_size # +######################################################################## + +SET @@global.query_prealloc_size = DEFAULT; +SELECT @@global.query_prealloc_size = 8192; + +SET @@session.query_prealloc_size = DEFAULT; +SELECT @@session.query_prealloc_size = 8192; + + +--echo '#--------------------FN_DYNVARS_005_03-------------------------#' +################################################################################## +# Change the value of query_prealloc_size to a valid value for GLOBAL Scope # +################################################################################## + +SET @@global.query_prealloc_size = 8192; +SELECT @@global.query_prealloc_size ; + +SET @@global.query_prealloc_size = 4294967295; +SELECT @@global.query_prealloc_size ; + +SET @@global.query_prealloc_size = 655354; +SELECT @@global.query_prealloc_size ; + + +--echo '#--------------------FN_DYNVARS_005_04-------------------------#' +################################################################################### +# Change the value of query_prealloc_size to a valid value for SESSION Scope # +################################################################################### + +SET @@session.query_prealloc_size = 8192; +SELECT @@session.query_prealloc_size ; + +SET @@session.query_prealloc_size = 4294967295; +SELECT @@session.query_prealloc_size ; + +SET @@session.query_prealloc_size = 655345; +SELECT @@session.query_prealloc_size ; + + + + +--echo '#------------------FN_DYNVARS_005_05-----------------------#' +#################################################################### +# Change the value of query_prealloc_size to an invalid value # +#################################################################### + +SET @@global.query_prealloc_size = 0; +SELECT @@global.query_prealloc_size ; + +SET @@global.query_prealloc_size = -1024; +SELECT @@global.query_prealloc_size ; + +SET @@global.query_prealloc_size = 429496729533; +SELECT @@global.query_prealloc_size ; + + +--Error ER_PARSE_ERROR +SET @@global.query_prealloc_size = 65530.34.; +SELECT @@global.query_prealloc_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_prealloc_size = test; +SELECT @@global.query_prealloc_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_prealloc_size = "test"; +SELECT @@global.query_prealloc_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_prealloc_size = 'test'; +SELECT @@global.query_prealloc_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.query_prealloc_size = ON; +SELECT @@global.query_prealloc_size ; + + +SET @@session.query_prealloc_size = 0; +SELECT @@session.query_prealloc_size ; + +SET @@session.query_prealloc_size = -2; +SELECT @@session.query_prealloc_size ; + +--Error ER_PARSE_ERROR + +SET @@session.query_prealloc_size = 65530.34.; +SELECT @@session.query_prealloc_size ; + + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.query_prealloc_size = test; +SELECT @@session.query_prealloc_size ; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.query_prealloc_size = "test"; +SELECT @@session.query_prealloc_size ; + + +--echo '#------------------FN_DYNVARS_005_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.query_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_prealloc_size '; + +--echo '#------------------FN_DYNVARS_005_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.query_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_prealloc_size '; + + +--echo '#------------------FN_DYNVARS_005_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.query_prealloc_size = TRUE; +SELECT @@global.query_prealloc_size ; +SET @@global.query_prealloc_size = FALSE; +SELECT @@global.query_prealloc_size ; + + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +#################################################################################### +# Check if accessing variable with and without GLOBAL point to same variable # +#################################################################################### + +SET @@global.query_prealloc_size = 10; +SELECT @@query_prealloc_size = @@global.query_prealloc_size ; + + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@query_prealloc_size = 100; +SELECT @@query_prealloc_size = @@local.query_prealloc_size ; +SELECT @@local.query_prealloc_size = @@session.query_prealloc_size ; + + +--echo '#---------------------FN_DYNVARS_001_11----------------------#' +################################################################################### +# Check if query_prealloc_size can be accessed with and without @@ sign # +################################################################################### + +SET query_prealloc_size = 1; +SELECT @@query_prealloc_size ; +--Error ER_UNKNOWN_TABLE + +SELECT local.query_prealloc_size ; + +--Error ER_UNKNOWN_TABLE +SELECT session.query_prealloc_size ; + +--Error ER_BAD_FIELD_ERROR +SELECT query_prealloc_size = @@session.query_prealloc_size ; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.query_prealloc_size = @start_global_value; +SELECT @@global.query_prealloc_size ; +SET @@session.query_prealloc_size = @start_session_value; +SELECT @@session.query_prealloc_size ; + + +############################################################# +# END OF query_prealloc_size TESTS # +############################################################# diff --git a/mysql-test/include/range_alloc_block_size_basic.inc b/mysql-test/include/range_alloc_block_size_basic.inc new file mode 100644 index 00000000000..37692cc8c35 --- /dev/null +++ b/mysql-test/include/range_alloc_block_size_basic.inc @@ -0,0 +1,208 @@ +############## mysql-test\t\range_alloc_block_size_basic.test ############### +# # +# Variable Name: range_alloc_block_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value:2048 # +# Max value: 4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable range_alloc_block_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +###################################################################### +# START OF range_alloc_block_size TESTS # +###################################################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.range_alloc_block_size; +SELECT @start_global_value; +SET @start_session_value = @@session.range_alloc_block_size; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_137_01-------------------------#' +###################################################################### +# Display the DEFAULT value of range_alloc_block_size # +###################################################################### + +SET @@global.range_alloc_block_size = 100; +SET @@global.range_alloc_block_size = DEFAULT; +SELECT @@global.range_alloc_block_size; + +SET @@session.range_alloc_block_size = 200; +SET @@session.range_alloc_block_size = DEFAULT; +SELECT @@session.range_alloc_block_size; + + +--echo '#--------------------FN_DYNVARS_137_02-------------------------#' +###################################################################### +# Check the DEFAULT value of range_alloc_block_size # +###################################################################### + +SET @@global.range_alloc_block_size = DEFAULT; +SELECT @@global.range_alloc_block_size = 2048; + +SET @@session.range_alloc_block_size = DEFAULT; +SELECT @@session.range_alloc_block_size = 2048; + + +--echo '#--------------------FN_DYNVARS_137_03-------------------------#' +################################################################################ +# Change the value of range_alloc_block_size to a valid value for GLOBAL Scope # +################################################################################ + +SET @@global.range_alloc_block_size = 2048; +SELECT @@global.range_alloc_block_size; +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.range_alloc_block_size = 4294967295; +SELECT @@global.range_alloc_block_size; +SET @@global.range_alloc_block_size = 4294967294; +SELECT @@global.range_alloc_block_size; +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + + +--echo '#--------------------FN_DYNVARS_137_04-------------------------#' +################################################################################### +# Change the value of range_alloc_block_size to a valid value for SESSION Scope # +################################################################################### + +SET @@session.range_alloc_block_size = 2048; +SELECT @@session.range_alloc_block_size; +SET @@session.range_alloc_block_size = 4294967295; +SELECT @@session.range_alloc_block_size; +SET @@session.range_alloc_block_size = 4294967294; +SELECT @@session.range_alloc_block_size; + + +--echo '#------------------FN_DYNVARS_137_05-----------------------#' +################################################################## +# Change the value of range_alloc_block_size to an invalid value # +################################################################## + +SET @@global.range_alloc_block_size = 0; +SELECT @@global.range_alloc_block_size; +SET @@global.range_alloc_block_size = -1024; +SELECT @@global.range_alloc_block_size; +SET @@global.range_alloc_block_size = 42949672951; +SELECT @@global.range_alloc_block_size; +--Error ER_PARSE_ERROR +SET @@global.range_alloc_block_size = 65530.34.; +SELECT @@global.range_alloc_block_size; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.range_alloc_block_size = test; +SELECT @@global.range_alloc_block_size; + +SET @@session.range_alloc_block_size = 0; +SELECT @@session.range_alloc_block_size; +SET @@session.range_alloc_block_size = -2; +SELECT @@session.range_alloc_block_size; +--Error ER_PARSE_ERROR +SET @@session.range_alloc_block_size = 65530.34.; +SET @@session.range_alloc_block_size = 4294967296; +SELECT @@session.range_alloc_block_size; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.range_alloc_block_size = test; +SELECT @@session.range_alloc_block_size; + + +--echo '#------------------FN_DYNVARS_137_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.range_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='range_alloc_block_size'; + +--echo '#------------------FN_DYNVARS_137_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.range_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='range_alloc_block_size'; + + +--echo '#------------------FN_DYNVARS_137_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.range_alloc_block_size = TRUE; +SELECT @@global.range_alloc_block_size; +SET @@global.range_alloc_block_size = FALSE; +SELECT @@global.range_alloc_block_size; + + +--echo '#---------------------FN_DYNVARS_137_09----------------------#' +#################################################################################### +# Check if accessing variable with and without GLOBAL point to same variable # +#################################################################################### + +SET @@global.range_alloc_block_size = 10; +SELECT @@range_alloc_block_size = @@global.range_alloc_block_size; + + +--echo '#---------------------FN_DYNVARS_137_10----------------------#' +######################################################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE points to same session variable # +######################################################################################################## + +SET @@range_alloc_block_size = 100; +SELECT @@range_alloc_block_size = @@local.range_alloc_block_size; +SELECT @@local.range_alloc_block_size = @@session.range_alloc_block_size; + + +--echo '#---------------------FN_DYNVARS_137_11----------------------#' +################################################################################### +# Check if range_alloc_block_size can be accessed with and without @@ sign # +################################################################################### + +SET range_alloc_block_size = 1; +SELECT @@range_alloc_block_size; +--Error ER_UNKNOWN_TABLE +SELECT local.range_alloc_block_size; +--Error ER_UNKNOWN_TABLE +SELECT session.range_alloc_block_size; +--Error ER_BAD_FIELD_ERROR +SELECT range_alloc_block_size = @@session.range_alloc_block_size; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.range_alloc_block_size = @start_global_value; +SELECT @@global.range_alloc_block_size; +SET @@session.range_alloc_block_size = @start_session_value; +SELECT @@session.range_alloc_block_size; + + +############################################################# +# END OF range_alloc_block_size TESTS # +############################################################# + diff --git a/mysql-test/include/rpl_recovery_rank_basic.inc b/mysql-test/include/rpl_recovery_rank_basic.inc new file mode 100644 index 00000000000..f9ae3968b31 --- /dev/null +++ b/mysql-test/include/rpl_recovery_rank_basic.inc @@ -0,0 +1,171 @@ +############## mysql-test\t\rpl_recovery_rank_basic.test ####################### +# # +# Variable Name: rpl_recovery_rank # +# Scope: GLOBAL & SESSION # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 1 # +# Range: 1 - 65536 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan Maredia # +# # +# Description: Test Cases of Dynamic System Variable rpl_recovery_rank # +# that checks the behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +################################################################################ + +--source include/load_sysvars.inc + +################################################################### +# START OF rpl_recovery_rank TESTS # +################################################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.rpl_recovery_rank; +SELECT @start_global_value; + +--echo '#--------------------FN_DYNVARS_142_01-------------------------#' +################################################################### +# Check the DEFAULT value of rpl_recovery_rank # +################################################################### + +SET @@global.rpl_recovery_rank = 500000; +SET @@global.rpl_recovery_rank = DEFAULT; +SELECT @@global.rpl_recovery_rank; + +--echo '#--------------------FN_DYNVARS_142_02-------------------------#' +################################################################################## +# Change the value of rpl_recovery_rank to a valid value for GLOBAL Scope # +################################################################################## + +SET @@global.rpl_recovery_rank = 0; +SELECT @@global.rpl_recovery_rank; +SET @@global.rpl_recovery_rank = 1024; +SELECT @@global.rpl_recovery_rank; +SET @@global.rpl_recovery_rank = 123456789; +SELECT @@global.rpl_recovery_rank; +SET @@global.rpl_recovery_rank = 2147483648*2; +SELECT @@global.rpl_recovery_rank; +SET @@global.rpl_recovery_rank = 2147483648*1024; +SELECT @@global.rpl_recovery_rank; +SELECT @@global.rpl_recovery_rank; +SET @@global.rpl_recovery_rank = 2147483648*2147483648; +SELECT @@global.rpl_recovery_rank; + + +--echo '#--------------------FN_DYNVARS_142_03-------------------------#' +################################################################################# +# Check if variable can be access with session scope # +################################################################################# + +--Error ER_GLOBAL_VARIABLE +SET @@rpl_recovery_rank = 2; + +--Error ER_GLOBAL_VARIABLE +SET @@session.rpl_recovery_rank = 3; + +--Error ER_GLOBAL_VARIABLE +SET @@local.rpl_recovery_rank = 4; + + + +--echo '#------------------FN_DYNVARS_142_04-----------------------#' +#################################################################### +# Change the value of rpl_recovery_rank to an invalid value # +#################################################################### + +SET @@global.rpl_recovery_rank = -1; +SELECT @@global.rpl_recovery_rank; +SET @@global.rpl_recovery_rank = -2147483648; +SELECT @@global.rpl_recovery_rank; +SET @@global.rpl_recovery_rank = -2147483649; +SELECT @@global.rpl_recovery_rank; +--Error ER_PARSE_ERROR +SET @@global.rpl_recovery_rank = 65530.34.; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.rpl_recovery_rank = 2147483649.56; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.rpl_recovery_rank = 1G; + + +--echo '#------------------FN_DYNVARS_142_05-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + +SET @@global.rpl_recovery_rank = 3000; +SELECT @@global.rpl_recovery_rank = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='rpl_recovery_rank'; + + +--echo '#------------------FN_DYNVARS_142_06-----------------------#' +########################################################################### +# Check if the value is present in INFORMATION_SCHEMA.SESSION_VARIABLES # +########################################################################### + +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='rpl_recovery_rank'; + + +--echo '#------------------FN_DYNVARS_142_07-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.rpl_recovery_rank = TRUE; +SELECT @@global.rpl_recovery_rank; +SET @@global.rpl_recovery_rank = FALSE; +SELECT @@global.rpl_recovery_rank; + + +--echo '#---------------------FN_DYNVARS_001_08----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + + +SET @@global.rpl_recovery_rank = 512; +SELECT @@rpl_recovery_rank = @@global.rpl_recovery_rank; + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +################################################################################## +# Check if rpl_recovery_rank can be accessed without @@ sign and scope # +################################################################################## + +--Error ER_GLOBAL_VARIABLE +SET rpl_recovery_rank = 2048; +--Error ER_BAD_FIELD_ERROR +SELECT rpl_recovery_rank; + +SELECT @@rpl_recovery_rank; + +#verifying another another syntax for setting value +SET global rpl_recovery_rank = 64; + +#################################### +# Restore initial value # +#################################### + +SET @@global.rpl_recovery_rank = @start_global_value; +SELECT @@global.rpl_recovery_rank; + +######################################################## +# END OF rpl_recovery_rank TESTS # +######################################################## + diff --git a/mysql-test/include/server_id_basic.inc b/mysql-test/include/server_id_basic.inc new file mode 100644 index 00000000000..47afadb5016 --- /dev/null +++ b/mysql-test/include/server_id_basic.inc @@ -0,0 +1,190 @@ +############## mysql-test\t\server_id_basic.test ################ +# # +# Variable Name: server_id # +# Scope: GLOBAL & SESSION # +# Access Type: Dynamic # +# Data Type: Numeric # +# Default Value: 1 # +# Range: 1 - 65536 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan Maredia # +# # +# Description: Test Cases of Dynamic System Variable server_id # +# that checks the behavior of this variable in the following ways # +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +################################################################################ + +--source include/load_sysvars.inc + +################################################################### +# START OF server_id TESTS # +################################################################### + + +############################################################# +# Save initial value # +############################################################# + +let $save_general_log= `SELECT @@global.general_log`; +SET @@global.general_log= 0; +SET @start_global_value = @@global.server_id; +SELECT @start_global_value; + +--echo '#--------------------FN_DYNVARS_144_01-------------------------#' +################################################################### +# Display the DEFAULT value of server_id # +################################################################### + +SET @@global.server_id = 500000; +SET @@global.server_id = DEFAULT; +SELECT @@global.server_id; + +--echo '#--------------------FN_DYNVARS_144_02-------------------------#' +################################################################### +# Check the DEFAULT value of server_id # +################################################################### + +SET @@global.server_id = DEFAULT; +SELECT @@global.server_id = 0; + +--echo '#--------------------FN_DYNVARS_144_03-------------------------#' +################################################################################## +# Change the value of server_id to a valid value for GLOBAL Scope # +################################################################################## + +SET @@global.server_id = 0; +SELECT @@global.server_id; +SET @@global.server_id = 1; +SELECT @@global.server_id; +SET @@global.server_id = 15; +SELECT @@global.server_id; +SET @@global.server_id = 1024; +SELECT @@global.server_id; +SET @@global.server_id = 123456789; +SELECT @@global.server_id; +SET @@global.server_id = 2147483648; +SELECT @@global.server_id; +SET @@global.server_id = 2147483648*2-1; +SELECT @@global.server_id; + + +--echo '#--------------------FN_DYNVARS_144_04-------------------------#' +################################################################################# +# Check if variable can be access with session scope # +################################################################################# + +--Error ER_GLOBAL_VARIABLE +SET @@server_id = 2; + +--Error ER_GLOBAL_VARIABLE +SET @@session.server_id = 3; + +--Error ER_GLOBAL_VARIABLE +SET @@local.server_id = 4; + + + +--echo '#------------------FN_DYNVARS_144_05-----------------------#' +#################################################################### +# Change the value of server_id to an invalid value # +#################################################################### + +SET @@global.server_id = -1; +SELECT @@global.server_id; + +SET @@global.server_id = -2147483648; +SELECT @@global.server_id; + +SET @@global.server_id = 2147483649*2; +SELECT @@global.server_id; + +--Error ER_PARSE_ERROR +SET @@global.server_id = 65530.34.; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.server_id = '125'; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.server_id = 7483649.56; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.server_id = 1G; + +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + + +--echo '#------------------FN_DYNVARS_144_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + +SET @@global.server_id = 3000; +SELECT @@global.server_id = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='server_id'; + + +--echo '#------------------FN_DYNVARS_144_07-----------------------#' +########################################################################### +# Check if the value is present in INFORMATION_SCHEMA.SESSION_VARIABLES # +########################################################################### + +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='server_id'; + + +--echo '#------------------FN_DYNVARS_144_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.server_id = TRUE; +SELECT @@global.server_id; +SET @@global.server_id = FALSE; +SELECT @@global.server_id; + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +################################################################################# +# Check if accessing variable with and without GLOBAL point to same variable # +################################################################################# + + +SET @@global.server_id = 512; +SELECT @@server_id = @@global.server_id; + + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +################################################################################## +# Check if server_id can be accessed without @@ sign and scope # +################################################################################## + +--Error ER_GLOBAL_VARIABLE +SET server_id = 2048; +--Error ER_BAD_FIELD_ERROR +SELECT server_id; + +SELECT @@server_id; + +#verifying another another syntax for setting value +SET global server_id = 99; + +#################################### +# Restore initial value # +#################################### + +SET @@global.server_id = @start_global_value; +SELECT @@global.server_id; + +eval SET @@global.general_log= $save_general_log; +######################################################## +# END OF server_id TESTS # +######################################################## + diff --git a/mysql-test/include/slave_transaction_retries_basic.inc b/mysql-test/include/slave_transaction_retries_basic.inc new file mode 100644 index 00000000000..6bbed3b1982 --- /dev/null +++ b/mysql-test/include/slave_transaction_retries_basic.inc @@ -0,0 +1,188 @@ +############# mysql-test\t\slave_transaction_retries_basic.test ############### +# # +# Variable Name: slave_transaction_retries # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 10 # +# Range: # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan # +# # +# Description: Test Cases of Dynamic System Variable slave_transaction_retries# +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +################################################################### +# START OF slave_transaction_retries TESTS # +################################################################### + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.slave_transaction_retries; +SELECT @start_global_value; + +--echo '#--------------------FN_DYNVARS_149_01-------------------------#' +################################################################### +# Display the DEFAULT value of slave_transaction_retries # +################################################################### + +SET @@global.slave_transaction_retries = 50; +SET @@global.slave_transaction_retries = DEFAULT; +SELECT @@global.slave_transaction_retries; + +--echo '#--------------------FN_DYNVARS_149_02-------------------------#' +################################################################### +# Check the DEFAULT value of slave_transaction_retries # +################################################################### + +SET @@global.slave_transaction_retries = DEFAULT; +SELECT @@global.slave_transaction_retries = 10; + +--echo '#--------------------FN_DYNVARS_149_03-------------------------#' +################################################################################ +# Change the value of slave_transaction_retries to a valid value for +# GLOBAL Scope +################################################################################ + +SET @@global.slave_transaction_retries = 0; +SELECT @@global.slave_transaction_retries; +SET @@global.slave_transaction_retries = 1; +SELECT @@global.slave_transaction_retries; +SET @@global.slave_transaction_retries = 15; +SELECT @@global.slave_transaction_retries; +SET @@global.slave_transaction_retries = 1024; +SELECT @@global.slave_transaction_retries; +SET @@global.slave_transaction_retries = 2147483648; +SELECT @@global.slave_transaction_retries; +SET @@global.slave_transaction_retries = 2147483648*2-1; +SELECT @@global.slave_transaction_retries; +SET @@global.slave_transaction_retries = 2147483649*2; +SELECT @@global.slave_transaction_retries; +SET @@global.slave_transaction_retries = 4294967295; +SELECT @@global.slave_transaction_retries; + +--echo '#--------------------FN_DYNVARS_149_04-------------------------#' +############################################################################### +# Check if variable can be access with session scope # +############################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@slave_transaction_retries = 2; + +--Error ER_GLOBAL_VARIABLE +SET @@session.slave_transaction_retries = 3; + +--Error ER_GLOBAL_VARIABLE +SET @@local.slave_transaction_retries = 4; + + + +--echo '#------------------FN_DYNVARS_149_05-----------------------#' +#################################################################### +# Change the value of slave_transaction_retries to an invalid value# +#################################################################### + +SET @@global.slave_transaction_retries = -1; +SELECT @@global.slave_transaction_retries; + +SET @@global.slave_transaction_retries = 2147483649*2147483649; +SELECT @@global.slave_transaction_retries; + +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + +--Error ER_PARSE_ERROR +SET @@global.slave_transaction_retries = 65530.34.; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.slave_transaction_retries = '100'; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.slave_transaction_retries = 7483649.56; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.slave_transaction_retries = ON; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.slave_transaction_retries = OFF; + +--echo '#------------------FN_DYNVARS_149_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + +SET @@global.slave_transaction_retries = 3000; +SELECT @@global.slave_transaction_retries = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='slave_transaction_retries'; + + +--echo '#------------------FN_DYNVARS_149_07-----------------------#' +########################################################################### +# Check if the value is present in INFORMATION_SCHEMA.SESSION_VARIABLES # +########################################################################### + +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='slave_transaction_retries'; + + +--echo '#------------------FN_DYNVARS_149_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.slave_transaction_retries = TRUE; +SELECT @@global.slave_transaction_retries; +SET @@global.slave_transaction_retries = FALSE; +SELECT @@global.slave_transaction_retries; + + +--echo '#---------------------FN_DYNVARS_149_09----------------------#' +############################################################################### +# Check if accessing variable with and without GLOBAL point to same variable # +############################################################################### + + +SET @@global.slave_transaction_retries = 60*60; +SELECT @@slave_transaction_retries = @@global.slave_transaction_retries; + + +--echo '#---------------------FN_DYNVARS_149_10----------------------#' +############################################################################### +# Check if slave_transaction_retries can be accessed without @@ sign +# and scope +############################################################################### + +--Error ER_GLOBAL_VARIABLE +SET slave_transaction_retries = 2048; +--Error ER_BAD_FIELD_ERROR +SELECT slave_transaction_retries; + +SELECT @@slave_transaction_retries; + +#verifying another another syntax for setting value +SET global slave_transaction_retries = 99; + +#################################### +# Restore initial value # +#################################### + +SET @@global.slave_transaction_retries = @start_global_value; +SELECT @@global.slave_transaction_retries; + +######################################################## +# END OF slave_transaction_retries TESTS # +######################################################## + diff --git a/mysql-test/include/sort_buffer_size_basic.inc b/mysql-test/include/sort_buffer_size_basic.inc new file mode 100644 index 00000000000..4dbae7c8847 --- /dev/null +++ b/mysql-test/include/sort_buffer_size_basic.inc @@ -0,0 +1,213 @@ +############## mysql-test\t\sort_buffer_size_basic.test ####################### +# # +# Variable Name: sort_buffer_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 2097144 # +# Range:max value:4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable sort_buffer_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +######################################################################## + + +###################################################################### +# START OF sort_buffer_size TESTS # +###################################################################### + + +############################################################# +# Save initial value # +############################################################# + +# due to difference when running on Windows (bug filed) +--source include/not_windows.inc + +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-------------------------#' +###################################################################### +# Display the DEFAULT value of sort_buffer_size # +###################################################################### + +SET @@global.sort_buffer_size = 1000; +SET @@global.sort_buffer_size = DEFAULT; +SELECT @@global.sort_buffer_size= 2097144 OR @@global.sort_buffer_size= 2097116; + +SET @@session.sort_buffer_size = 2000; +SET @@session.sort_buffer_size = DEFAULT; +SELECT @@session.sort_buffer_size= 2097144 OR @@session.sort_buffer_size= 2097116; + + +--echo '#--------------------FN_DYNVARS_151_02-------------------------#' +###################################################################### +# Check the DEFAULT value of sort_buffer_size # +###################################################################### + +SET @@global.sort_buffer_size = DEFAULT; +SELECT @@global.sort_buffer_size = 2097144 OR @@global.sort_buffer_size= 2097116; + +SET @@session.sort_buffer_size = DEFAULT; +SELECT @@session.sort_buffer_size = 2097144 OR @@session.sort_buffer_size= 2097116; + + +--echo '#--------------------FN_DYNVARS_151_03-------------------------#' +################################################################################ +# Change the value of sort_buffer_size to a valid value for GLOBAL Scope # +################################################################################ + +SET @@global.sort_buffer_size = 32776; +SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804; +SET @@global.sort_buffer_size = 32777; +SELECT @@global.sort_buffer_size= 32777 OR @@global.sort_buffer_size= 32804; +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-------------------------#' +################################################################################### +# Change the value of sort_buffer_size to a valid value for SESSION Scope # +################################################################################### + +SET @@session.sort_buffer_size = 32776; +SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804; +SET @@session.sort_buffer_size = 32777; +SELECT @@session.sort_buffer_size= 32777 OR @@session.sort_buffer_size= 32804; +SET @@session.sort_buffer_size = 4294967295; +SELECT @@session.sort_buffer_size; +SET @@session.sort_buffer_size = 4294967294; +SELECT @@session.sort_buffer_size; + + +--echo '#------------------FN_DYNVARS_151_05-----------------------#' +################################################################## +# Change the value of sort_buffer_size to an invalid value # +################################################################## + +SET @@global.sort_buffer_size = 32775; +SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804; +SET @@global.sort_buffer_size = -1024; +SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804; +SET @@global.sort_buffer_size = 4294967296; +SELECT @@global.sort_buffer_size; +--Error ER_PARSE_ERROR +SET @@global.sort_buffer_size = 65530.34.; +SELECT @@global.sort_buffer_size; +--Error ER_WRONG_TYPE_FOR_VAR +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; +SET @@session.sort_buffer_size = -2; +SELECT @@session.sort_buffer_size= 32776 OR @@session.sort_buffer_size= 32804; +--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-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +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'; + + +--echo '#------------------FN_DYNVARS_151_08-----------------------#' +#################################################################### +# Check if TRUE and FALSE values can be used on variable # +#################################################################### + +SET @@global.sort_buffer_size = TRUE; +SELECT @@global.sort_buffer_size= 32776 OR @@global.sort_buffer_size= 32804; +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'; + + +--echo '#---------------------FN_DYNVARS_151_09----------------------#' +#################################################################################### +# Check if accessing variable with and without GLOBAL point to same 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 # +######################################################################################################## + +SET @@sort_buffer_size = 9000; +SELECT @@sort_buffer_size = @@local.sort_buffer_size; +SELECT @@local.sort_buffer_size = @@session.sort_buffer_size; + + +--echo '#---------------------FN_DYNVARS_151_11----------------------#' +################################################################################### +# Check if sort_buffer_size can be accessed with and without @@ sign # +################################################################################### + +SET sort_buffer_size = 9100; +SELECT @sort_buffer_size= 32776 OR @@sort_buffer_size= 32804; +SELECT @@sort_buffer_size; +--Error ER_UNKNOWN_TABLE +SELECT local.sort_buffer_size; +--Error ER_UNKNOWN_TABLE +SELECT session.sort_buffer_size; +--Error ER_BAD_FIELD_ERROR +SELECT sort_buffer_size = @@session.sort_buffer_size; + + +#################################### +# Restore initial value # +#################################### + +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; + + +############################################################# +# END OF sort_buffer_size TESTS # +############################################################# diff --git a/mysql-test/include/sync_binlog_basic.inc b/mysql-test/include/sync_binlog_basic.inc new file mode 100644 index 00000000000..b66509bbb5e --- /dev/null +++ b/mysql-test/include/sync_binlog_basic.inc @@ -0,0 +1,156 @@ +#################### mysql-test\t\sync_binlog_basic.test ###################### +# # +# Variable Name: sync_binlog # +# Scope: GLOBAL # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 0 # +# Range: 0 - 4294967295 # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Salman Rawala # +# # +# Description: Test Cases of Dynamic System Variable sync_binlog # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +################################################################## +# START OF sync_binlog TESTS # +################################################################## + + +################################################################## +# Saving initial value of sync_binlog in a temporary variable # +################################################################## + +SET @start_value = @@global.sync_binlog; +SELECT @start_value; + + +--echo '#--------------------FN_DYNVARS_168_01------------------------#' +################################################################## +# Display the DEFAULT value of sync_binlog # +################################################################## + +SET @@global.sync_binlog = 99; +SET @@global.sync_binlog = DEFAULT; +SELECT @@global.sync_binlog; + + +--echo '#---------------------FN_DYNVARS_168_02-------------------------#' +############################################### +# Verify default value of variable # +############################################### + +SET @@global.sync_binlog = @start_value; +SELECT @@global.sync_binlog = 0; + + +--echo '#--------------------FN_DYNVARS_168_03------------------------#' +################################################################### +# Change the value of sync_binlog to a valid value # +################################################################### + +SET @@global.sync_binlog = 0; +SELECT @@global.sync_binlog; +SET @@global.sync_binlog = 1; +SELECT @@global.sync_binlog; +SET @@global.sync_binlog = 4294967295; +SELECT @@global.sync_binlog; +SET @@global.sync_binlog = 4294967294; +SELECT @@global.sync_binlog; +SET @@global.sync_binlog = 65536; +SELECT @@global.sync_binlog; + + +--echo '#--------------------FN_DYNVARS_168_04-------------------------#' +###################################################################### +# Change the value of sync_binlog to invalid value # +###################################################################### + +SET @@global.sync_binlog = -1; +SELECT @@global.sync_binlog; +SET @@global.sync_binlog = 4294967296; +SELECT @@global.sync_binlog; +SET @@global.sync_binlog = 10240022115; +SELECT @@global.sync_binlog; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.sync_binlog = 10000.01; +SELECT @@global.sync_binlog; +SET @@global.sync_binlog = -1024; +SELECT @@global.sync_binlog; +SET @@global.sync_binlog = 42949672950; +SELECT @@global.sync_binlog; +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.sync_binlog = ON; +SELECT @@global.sync_binlog; +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.sync_binlog = 'test'; +SELECT @@global.sync_binlog; + + +--echo '#-------------------FN_DYNVARS_168_05----------------------------#' +########################################################################### +# Test if accessing session sync_binlog gives error # +########################################################################### + +--Error ER_GLOBAL_VARIABLE +SET @@session.sync_binlog = 0; +SELECT @@sync_binlog; + + +--echo '#----------------------FN_DYNVARS_168_06------------------------#' +############################################################################## +# Check if the value in GLOBAL & SESSION Tables matches values in variable # +############################################################################## + +SELECT @@global.sync_binlog = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='sync_binlog'; + + + +--echo '#---------------------FN_DYNVARS_168_07----------------------#' +########################################################################## +# Check if sync_binlog can be accessed with and without @@ sign # +########################################################################## + +--Error ER_GLOBAL_VARIABLE +SET sync_binlog = 1; +SELECT @@sync_binlog; +--Error ER_PARSE_ERROR +SET local.sync_binlog = 1; +--Error ER_UNKNOWN_TABLE +SELECT local.sync_binlog; +--Error ER_PARSE_ERROR +SET global.sync_binlog = 1; +--Error ER_UNKNOWN_TABLE +SELECT global.sync_binlog; +--Error ER_BAD_FIELD_ERROR +SELECT sync_binlog = @@session.sync_binlog; + + +############################## +# Restore initial value # +############################## + +SET @@global.sync_binlog = @start_value; +SELECT @@global.sync_binlog; + + +######################################################################## +# END OF sync_binlog TESTS # +######################################################################## diff --git a/mysql-test/include/timestamp_basic.inc b/mysql-test/include/timestamp_basic.inc new file mode 100644 index 00000000000..d7ad620ec26 --- /dev/null +++ b/mysql-test/include/timestamp_basic.inc @@ -0,0 +1,162 @@ +################## mysql-test\t\timestamp_basic.test ########################## +# # +# Variable Name: timestamp # +# Scope: SESSION # +# Access Type: Dynamic # +# Data Type: string # +# Default Value: # +# Range: # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Rizwan # +# # +# Description: Test Cases of Dynamic System Variable timestamp # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +####################################################################### +# START OF timestamp TESTS # +####################################################################### + + +####################################################################### +# Saving initial value of timestamp in a temporary variable # +####################################################################### + +SET @session_start_value = @@session.timestamp; + +--echo '#--------------------FN_DYNVARS_001_01------------------------#' +######################################################################## +# Display the DEFAULT value of timestamp # +######################################################################## + + +SET @@timestamp = DEFAULT; +#SELECT @@timestamp; + +--echo 'timestamp does not have any DEFAULT value' + +--echo '#---------------------FN_DYNVARS_001_02-------------------------#' +############################################################## +# see if accessable using global scope # +############################################################## + +--Error ER_LOCAL_VARIABLE +SET @@global.timestamp = "1000"; + + +--echo '#--------------------FN_DYNVARS_001_03------------------------#' +######################################################################## +# Change the value of timestamp to a valid value # +######################################################################## + +SET @@timestamp = 0; +#SELECT @@timestamp; + +--echo 'Setting 0 resets timestamp to session default timestamp' + +SET @@timestamp = 123456789123456; +SELECT @@timestamp; +SET @@timestamp = 60*60*60*60*365; +SELECT @@timestamp; +SET @@timestamp = -1000000000; +SELECT @@timestamp; + +SET @temp_ts = @@timestamp - @@timestamp; +SELECT @temp_ts; + +--echo '#--------------------FN_DYNVARS_001_04-------------------------#' +########################################################################### +# Change the value of timestamp to invalid value # +########################################################################### + +# for session scope +--Error ER_WRONG_TYPE_FOR_VAR +SET @@timestamp = "100"; +--echo 'Bug# 34836: Documentation says its a string variable but infact its numeric' + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@timestamp = " "; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@timestamp = 1.1; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@timestamp = 9999999999999999999999; + + + +--echo '#----------------------FN_DYNVARS_001_06------------------------#' +######################################################################### +# Check if the value in SESSION Table matches value in variable # +######################################################################### + +SELECT @@timestamp = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='timestamp'; + +--echo '#---------------------FN_DYNVARS_001_08-------------------------#' +############################################################################# +# Check if ON, OFF, TRUE and FALSE values can be used on variable # +############################################################################# +--Error ER_WRONG_TYPE_FOR_VAR +SET @@timestamp = OFF; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@timestamp = ON; + +SET @@timestamp = TRUE; +SELECT @@timestamp; + +SET @@timestamp = FALSE; +#SELECT @@timestamp; + + + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +############################################################################# +# Check if accessing variable with SESSION,LOCAL and without SCOPE points +# to same session variable +############################################################################# + +SET @@timestamp = 123456; +SELECT @@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp; +SET @@timestamp = 654321; +SELECT @@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp; + + +--echo '#---------------------FN_DYNVARS_001_11----------------------#' +##################################################################### +# Check if timestamp can be accessed with and without @@ sign # +##################################################################### + +SET timestamp = 1; +SELECT @@timestamp; +--Error ER_UNKNOWN_TABLE +SELECT local.timestamp; +--Error ER_UNKNOWN_TABLE +SELECT session.timestamp; +--Error ER_BAD_FIELD_ERROR +SELECT timestamp = @@session.timestamp; + +############################## +# Restore initial value # +############################## + +SET @@timestamp = @session_start_value; + +####################################################################### +# END OF timestamp TESTS # +####################################################################### + diff --git a/mysql-test/include/tmp_table_size_basic.inc b/mysql-test/include/tmp_table_size_basic.inc new file mode 100644 index 00000000000..7f69bcd1f8c --- /dev/null +++ b/mysql-test/include/tmp_table_size_basic.inc @@ -0,0 +1,233 @@ +############## mysql-test\t\tmp_table_size_basic.test ######################### +# # +# Variable Name: tmp_table_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 33554432 # +# Range: 1024-4294967295 # +# # +# # +# Creation Date: 2008-02-13 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable tmp_table_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html#option_mysqld_tmp_table_size # +# # +############################################################################### + +--source include/load_sysvars.inc + +############################################################## +# START OF tmp_table_size TESTS # +############################################################## + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.tmp_table_size; +SELECT @start_global_value; +SET @start_session_value = @@session.tmp_table_size; +SELECT @start_session_value; + +--echo 'Bug# 34876: This variable has invalid default value as compared to documentation'; + +--echo '#--------------------FN_DYNVARS_005_01-------------------------#' +############################################################## +# Display the DEFAULT value of tmp_table_size # +############################################################## + +SET @@global.tmp_table_size = 100; +SET @@global.tmp_table_size = DEFAULT; +SELECT @@global.tmp_table_size; + +--echo 'Bug# 34876: This variable has invalid default value as compared to documentation'; +SET @@session.tmp_table_size = 200; +SET @@session.tmp_table_size = DEFAULT; +SELECT @@session.tmp_table_size; +--echo 'Bug# 34876: This variable has invalid default value as compared to documentation'; + + +--echo '#--------------------FN_DYNVARS_005_02-------------------------#' +######################################################################## +# Check the DEFAULT value of tmp_table_size # +######################################################################## + +SET @@global.tmp_table_size = DEFAULT; +SELECT @@global.tmp_table_size = 33554432; + +SET @@session.tmp_table_size = DEFAULT; +SELECT @@session.tmp_table_size = 33554432; + +--echo 'Bug# 34876: This variable has invalid default value as compared to documentation'; + +--echo '#--------------------FN_DYNVARS_005_03-------------------------#' +######################################################################## +# Change the value of tmp_table_size to a valid value for GLOBAL Scope # +######################################################################## + +SET @@global.tmp_table_size = 1024; +SELECT @@global.tmp_table_size; +SET @@global.tmp_table_size = 60020; +SELECT @@global.tmp_table_size; +SET @@global.tmp_table_size = 4294967295; +SELECT @@global.tmp_table_size; + + +--echo '#--------------------FN_DYNVARS_005_04-------------------------#' +######################################################################### +# Change the value of tmp_table_size to a valid value for SESSION Scope # +######################################################################### + +SET @@session.tmp_table_size = 1024; +SELECT @@session.tmp_table_size; + +SET @@session.tmp_table_size =4294967295; +SELECT @@session.tmp_table_size; +SET @@session.tmp_table_size = 65535; +SELECT @@session.tmp_table_size; + + +--echo '#------------------FN_DYNVARS_005_05-----------------------#' +########################################################## +# Change the value of tmp_table_size to an invalid value # +########################################################## + +SET @@global.tmp_table_size = 0; +SELECT @@global.tmp_table_size; + +SET @@global.tmp_table_size = -1024; +SELECT @@global.tmp_table_size; + +SET @@global.tmp_table_size = 1000; +SELECT @@global.tmp_table_size; + +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.tmp_table_size = ON; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.tmp_table_size = OFF; + + +SET @@global.tmp_table_size = True; +SELECT @@global.tmp_table_size; + +SET @@global.tmp_table_size = False; +SELECT @@global.tmp_table_size; +--echo 'Bug:Error should be shown that variable is numeric and can not assigned boolean value'; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.tmp_table_size = 65530.34; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.tmp_table_size ="Test"; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@session.tmp_table_size = ON; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@session.tmp_table_size = OFF; + +SET @@session.tmp_table_size = True; +SELECT @@session.tmp_table_size; + +SET @@session.tmp_table_size = False; +SELECT @@session.tmp_table_size; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@session.tmp_table_size = "Test"; + +SET @@session.tmp_table_size = 12345678901; +SELECT @@session.tmp_table_size; + + +--echo '#------------------FN_DYNVARS_005_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.tmp_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='tmp_table_size'; + +--echo '#------------------FN_DYNVARS_005_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.tmp_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='tmp_table_size'; + + + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +######################################################################## +# Check if global and session variables are independent of each other # +######################################################################## + +SET @@global.tmp_table_size = 1024; +SET @@tmp_table_size = 4294967295; +SELECT @@tmp_table_size = @@global.tmp_table_size; + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +################################################################## +# Check if accessing variable with SESSION,LOCAL and without # +# SCOPE points to same session variable # +################################################################## + +SET @@tmp_table_size = 100; +SELECT @@tmp_table_size = @@local.tmp_table_size; +SELECT @@local.tmp_table_size = @@session.tmp_table_size; + + +--echo '#---------------------FN_DYNVARS_001_11----------------------#' +######################################################################### +# Check if tmp_table_size can be accessed with and without @@ sign # +######################################################################### + +SET tmp_table_size = 1027; +SELECT @@tmp_table_size; + +--Error ER_UNKNOWN_TABLE +SELECT local.tmp_table_size; + +--Error ER_UNKNOWN_TABLE +SELECT global.tmp_table_size; + +--Error ER_BAD_FIELD_ERROR +SELECT tmp_table_size = @@session.tmp_table_size; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.tmp_table_size = @start_global_value; +SELECT @@global.tmp_table_size; +SET @@session.tmp_table_size = @start_session_value; +SELECT @@session.tmp_table_size; + + +################################################### +# END OF tmp_table_size TESTS # +################################################### + diff --git a/mysql-test/include/transaction_alloc_block_size_basic.inc b/mysql-test/include/transaction_alloc_block_size_basic.inc new file mode 100644 index 00000000000..c14383b86c6 --- /dev/null +++ b/mysql-test/include/transaction_alloc_block_size_basic.inc @@ -0,0 +1,240 @@ +############## mysql-test\t\transaction_alloc_block_size_basic.test ########### +# # +# Variable Name: transaction_alloc_block_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 8192 # +# Range: 1024-4294967295 # +# # +# # +# Creation Date: 2008-02-14 # +# Author: Salman # +# # +# Description: Test Cases of Dynamic System Variable # +# transaction_alloc_block_size # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html # +# # +############################################################################### + +--source include/load_sysvars.inc + +######################################################################## +# START OF transaction_alloc_block_size TESTS # +######################################################################## + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.transaction_alloc_block_size; +SELECT @start_global_value; +SET @start_session_value = @@session.transaction_alloc_block_size; +SELECT @start_session_value; + + +--echo '#--------------------FN_DYNVARS_005_01-------------------------#' +######################################################################## +# Display the DEFAULT value of transaction_alloc_block_size # +######################################################################## + +SET @@global.transaction_alloc_block_size = 100; +SET @@global.transaction_alloc_block_size = DEFAULT; +SELECT @@global.transaction_alloc_block_size; + + +SET @@session.transaction_alloc_block_size = 200; +SET @@session.transaction_alloc_block_size = DEFAULT; +SELECT @@session.transaction_alloc_block_size; + + + +--echo '#--------------------FN_DYNVARS_005_02-------------------------#' +######################################################################## +# Check the DEFAULT value of transaction_alloc_block_size # +######################################################################## + +SET @@global.transaction_alloc_block_size = DEFAULT; +SELECT @@global.transaction_alloc_block_size = 8192; + +SET @@session.transaction_alloc_block_size = DEFAULT; +SELECT @@session.transaction_alloc_block_size = 8192; + + +--echo '#--------------------FN_DYNVARS_005_03-------------------------#' +################################################################## +# Change the value of variable to a valid value for GLOBAL Scope # +################################################################## + +SET @@global.transaction_alloc_block_size = 1024; +SELECT @@global.transaction_alloc_block_size; + +SET @@global.transaction_alloc_block_size = 60020; +SELECT @@global.transaction_alloc_block_size; + +SET @@global.transaction_alloc_block_size = 4294967295; +SELECT @@global.transaction_alloc_block_size; +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + +--echo '#--------------------FN_DYNVARS_005_04-------------------------#' +################################################################### +# Change the value of variable to a valid value for SESSION Scope # +################################################################### + +SET @@session.transaction_alloc_block_size = 1024; +SELECT @@session.transaction_alloc_block_size; + +SET @@session.transaction_alloc_block_size =4294967295; +SELECT @@session.transaction_alloc_block_size; + +SET @@session.transaction_alloc_block_size = 65535; +SELECT @@session.transaction_alloc_block_size; +--echo 'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; + + +--echo '#------------------FN_DYNVARS_005_05-----------------------#' +######################################################################## +# Change the value of transaction_alloc_block_size to an invalid value # +######################################################################## + +SET @@global.transaction_alloc_block_size = 0; +SELECT @@global.transaction_alloc_block_size; + +SET @@global.transaction_alloc_block_size = -1024; +SELECT @@global.transaction_alloc_block_size; + + +SET @@global.transaction_alloc_block_size = 123456789201; +SELECT @@global.transaction_alloc_block_size; + +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.transaction_alloc_block_size = ON; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.transaction_alloc_block_size = OFF; + + +SET @@global.transaction_alloc_block_size = True; +SELECT @@global.transaction_alloc_block_size; + +SET @@global.transaction_alloc_block_size = False; +SELECT @@global.transaction_alloc_block_size; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.transaction_alloc_block_size = 65530.34; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.transaction_alloc_block_size ="Test"; + +SET @@global.transaction_alloc_block_size = 1000; +SELECT @@global.transaction_alloc_block_size; + +SET @@session.transaction_alloc_block_size = 12345678901; +SELECT @@session.transaction_alloc_block_size; + +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@session.transaction_alloc_block_size = ON; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@session.transaction_alloc_block_size = OFF; + +SET @@session.transaction_alloc_block_size = True; +SELECT @@session.transaction_alloc_block_size; + +SET @@session.transaction_alloc_block_size = False; +SELECT @@session.transaction_alloc_block_size; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@session.transaction_alloc_block_size = "Test"; + + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.transaction_alloc_block_size = 'test'; + +--echo '#------------------FN_DYNVARS_005_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.transaction_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='transaction_alloc_block_size'; + +--echo '#------------------FN_DYNVARS_005_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.transaction_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='transaction_alloc_block_size'; + + +--echo '#---------------------FN_DYNVARS_001_08----------------------#' +########################################################################### +# Check if global and session variable are independent of each other # +########################################################################### + +SET @@transaction_alloc_block_size = 1024; +SET @@global.transaction_alloc_block_size = 4294967295; +SELECT @@transaction_alloc_block_size = @@global.transaction_alloc_block_size; + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +######################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE # +# points to same session variable # +######################################################################## + +SET @@transaction_alloc_block_size = 100; +SELECT @@transaction_alloc_block_size = @@local.transaction_alloc_block_size; +SELECT @@local.transaction_alloc_block_size = @@session.transaction_alloc_block_size; + + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +################################################################ +# Check if variable can be accessed with and without @@ sign # +################################################################ + +SET transaction_alloc_block_size = 1027; +SELECT @@transaction_alloc_block_size; + +--Error ER_UNKNOWN_TABLE +SELECT local.transaction_alloc_block_size; + +--Error ER_UNKNOWN_TABLE +SELECT session.transaction_alloc_block_size; + +--Error ER_BAD_FIELD_ERROR +SELECT transaction_alloc_block_size = @@session.transaction_alloc_block_size; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.transaction_alloc_block_size = @start_global_value; +SELECT @@global.transaction_alloc_block_size; +SET @@session.tmp_table_size = @start_session_value; +SELECT @@session.transaction_alloc_block_size; + + +############################################################# +# END OF transaction_alloc_block_size TESTS # +############################################################# + diff --git a/mysql-test/include/transaction_prealloc_size_basic.inc b/mysql-test/include/transaction_prealloc_size_basic.inc new file mode 100644 index 00000000000..1ca302a19e0 --- /dev/null +++ b/mysql-test/include/transaction_prealloc_size_basic.inc @@ -0,0 +1,229 @@ +############## mysql-test\t\transaction_prealloc_size_basic.test ############## +# # +# Variable Name: transaction_prealloc_size # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: 4096 # +# Range: # +# # +# # +# Creation Date: 2008-02-14 # +# Author: Sharique Abdullah # +# # +# Description: Test Cases of Dynamic System Variable transaction_prealloc_size# +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html#option_mysqld_transaction_prealloc_size # +# # +############################################################################### + +--source include/load_sysvars.inc + +######################################################################## +# START OF transaction_prealloc_size TESTS # +######################################################################## + + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.transaction_prealloc_size; +SELECT @start_global_value; +SET @start_session_value = @@session.transaction_prealloc_size; +SELECT @start_session_value; + +--echo 'Bug# 34876: This variable has invalid default value as compared to documentation'; + +--echo '#--------------------FN_DYNVARS_005_01-------------------------#' +######################################################################## +# Display the DEFAULT value of transaction_prealloc_size # +######################################################################## + +SET @@global.transaction_prealloc_size = 100; +SET @@global.transaction_prealloc_size = DEFAULT; +SELECT @@global.transaction_prealloc_size; + + +SET @@session.transaction_prealloc_size = 200; +SET @@session.transaction_prealloc_size = DEFAULT; +SELECT @@session.transaction_prealloc_size; + +--echo '#--------------------FN_DYNVARS_005_02-------------------------#' +######################################################################## +# Check the DEFAULT value of transaction_prealloc_size # +######################################################################## + +SET @@global.transaction_prealloc_size = DEFAULT; +SELECT @@global.transaction_prealloc_size = 4096; + +SET @@session.transaction_prealloc_size = DEFAULT; +SELECT @@session.transaction_prealloc_size = 4096; + +--echo '#--------------------FN_DYNVARS_005_03-------------------------#' +################################################################## +# Change the value of variable to a valid value for GLOBAL Scope # +################################################################## + +SET @@global.transaction_prealloc_size = 1024; +SELECT @@global.transaction_prealloc_size; + +SET @@global.transaction_prealloc_size = 60020; +SELECT @@global.transaction_prealloc_size; + +SET @@global.transaction_prealloc_size = 4294966272; +SELECT @@global.transaction_prealloc_size; + + +--echo '#--------------------FN_DYNVARS_005_04-------------------------#' +################################################################### +# Change the value of variable to a valid value for SESSION Scope # +################################################################### + +SET @@session.transaction_prealloc_size = 1024; +SELECT @@session.transaction_prealloc_size; + +SET @@session.transaction_prealloc_size =4294966272; +SELECT @@session.transaction_prealloc_size; +SET @@session.transaction_prealloc_size = 65535; +SELECT @@session.transaction_prealloc_size; + + +--echo '#------------------FN_DYNVARS_005_05-----------------------#' +##################################################################### +# Change the value of transaction_prealloc_size to an invalid value # +##################################################################### + +SET @@global.transaction_prealloc_size = 0; +SELECT @@global.transaction_prealloc_size; + +SET @@global.transaction_prealloc_size = -1024; +SELECT @@global.transaction_prealloc_size; + +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.transaction_prealloc_size = ON; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.transaction_prealloc_size = OFF; + + +SET @@global.transaction_prealloc_size = True; +SELECT @@global.transaction_prealloc_size; + +SET @@global.transaction_prealloc_size = False; +SELECT @@global.transaction_prealloc_size; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.transaction_prealloc_size = 65530.34; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@global.transaction_prealloc_size ="Test"; + +SET @@global.transaction_prealloc_size = 1000; +SELECT @@global.transaction_prealloc_size; + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@session.transaction_prealloc_size = ON; + + +-- Error ER_WRONG_TYPE_FOR_VAR +SET @@session.transaction_prealloc_size = OFF; + +SET @@session.transaction_prealloc_size = True; +SELECT @@session.transaction_prealloc_size; + +SET @@session.transaction_prealloc_size = False; +SELECT @@session.transaction_prealloc_size; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.transaction_prealloc_size = "Test"; + +SET @@session.transaction_prealloc_size = 123456789031; +SELECT @@session.transaction_prealloc_size; + + +--echo '#------------------FN_DYNVARS_005_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + + +SELECT @@global.transaction_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='transaction_prealloc_size'; + +--echo '#------------------FN_DYNVARS_005_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.transaction_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='transaction_prealloc_size'; + + + + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +########################################################################### +# Check if global and session variable are independent of each other # +########################################################################### + +SET @@global.transaction_prealloc_size = 1024; +SET @@global.transaction_prealloc_size = 10; + +SELECT @@transaction_prealloc_size = @@global.transaction_prealloc_size; + + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +######################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE # +# points to same session variable # +######################################################################## + +SET @@transaction_prealloc_size = 100; +SELECT @@transaction_prealloc_size = @@local.transaction_prealloc_size; +SELECT @@local.transaction_prealloc_size = @@session.transaction_prealloc_size; + + +--echo '#---------------------FN_DYNVARS_001_11----------------------#' +############################################################################### +# Check if transaction_prealloc_size can be accessed with and without @@ sign # +############################################################################### + +SET transaction_prealloc_size = 1027; +SELECT @@transaction_prealloc_size; + +--Error ER_UNKNOWN_TABLE +SELECT local.transaction_prealloc_size; + +--Error ER_UNKNOWN_TABLE +SELECT session.transaction_prealloc_size; + +--Error ER_BAD_FIELD_ERROR +SELECT transaction_prealloc_size = @@session.transaction_prealloc_size; + +#################################### +# Restore initial value # +#################################### + +SET @@global.transaction_prealloc_size = @start_global_value; +SELECT @@global.transaction_prealloc_size; +SET @@session.transaction_prealloc_size = @start_session_value; +SELECT @@session.transaction_prealloc_size; + + +############################################################# +# END OF transaction_prealloc_size TESTS # +############################################################# + diff --git a/mysql-test/include/wait_timeout_basic.inc b/mysql-test/include/wait_timeout_basic.inc new file mode 100644 index 00000000000..b6e19e235ba --- /dev/null +++ b/mysql-test/include/wait_timeout_basic.inc @@ -0,0 +1,218 @@ +############## mysql-test\t\wait_timeout_basic.test ########################### +# # +# Variable Name: wait_timeout # +# Scope: GLOBAL | SESSION # +# Access Type: Dynamic # +# Data Type: numeric # +# Default Value: # +# Range: # +# # +# # +# Creation Date: 2008-02-07 # +# Author: Sharique Abdullah # +# # +# Description: Test Cases of Dynamic System Variable wait_timeout # +# that checks the behavior of this variable in the following ways# +# * Default Value # +# * Valid & Invalid values # +# * Scope & Access method # +# * Data Integrity # +# # +# Reference: http://dev.mysql.com/doc/refman/5.1/en/ # +# server-system-variables.html#option_mysqld_wait_timeouts # +# # +############################################################################### +# Due to differnces between linux and windows in the results + +--source include/not_windows.inc +--source include/load_sysvars.inc + +############################################################ +# START OF wait_timeout TESTS # +############################################################ + +############################################################# +# Save initial value # +############################################################# + +SET @start_global_value = @@global.wait_timeout; +SET @start_session_value = @@session.wait_timeout; + +--echo '#--------------------FN_DYNVARS_005_01-------------------------#' +############################################################ +# Display the DEFAULT value of wait_timeout # +############################################################ + +SET @@global.wait_timeout = 100; +SET @@global.wait_timeout = DEFAULT; +SELECT @@global.wait_timeout; + +SET @@session.wait_timeout = 200; +SET @@session.wait_timeout = DEFAULT; +SELECT @@session.wait_timeout; + + +--echo '#--------------------FN_DYNVARS_005_02-------------------------#' +############################################################ +# Check the DEFAULT value of wait_timeout # +############################################################ + +SET @@global.wait_timeout = DEFAULT; +SELECT @@global.wait_timeout = @default_wait_timeout; + +SET @@session.wait_timeout = DEFAULT; +SELECT @@session.wait_timeout = @default_wait_timeout; + + + +--echo '#--------------------FN_DYNVARS_005_03-------------------------#' +###################################################################### +# Change the value of wait_timeout to a valid value for GLOBAL Scope # +###################################################################### + +#SET @@global.wait_timeout= @min_wait_timeout; +SET @@global.wait_timeout= 1; +SELECT @@global.wait_timeout; + +SET @@global.wait_timeout = 60020; +SELECT @@global.wait_timeout; + +#SET @@global.wait_timeout = @max_wait_timeout; +SET @@global.wait_timeout = 31536000; +SELECT @@global.wait_timeout = @max_wait_timeout; + + +--echo '#--------------------FN_DYNVARS_005_04-------------------------#' +####################################################################### +# Change the value of wait_timeout to a valid value for SESSION Scope # +####################################################################### +#SET @@session.wait_timeout = @min_wait_timeout; +#SELECT @@session.wait_timeout; + +SET @@session.wait_timeout =6000; +SELECT @@session.wait_timeout; + +#SET @@session.wait_timeout = @max_wait_timeout; +#SELECT @@session.wait_timeout = @max_wait_timeout; + + +--echo '#------------------FN_DYNVARS_005_05-----------------------#' +######################################################## +# Change the value of wait_timeout to an invalid value # +######################################################## + +SET @@global.wait_timeout = 0; +SET @@global.wait_timeout = -1024; + +--echo 'Bug # 34837: Errors are not coming on assigning invalid values to variable'; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.wait_timeout = ON; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.wait_timeout = OFF; + +SET @@global.wait_timeout = True; +SELECT @@global.wait_timeout; + +SET @@global.wait_timeout = False; +SELECT @@global.wait_timeout; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.wait_timeout = 65530.34; + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@global.wait_timeout ="Test"; + + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.wait_timeout = ON; + + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.wait_timeout = OFF; + +SET @@session.wait_timeout = True; +SELECT @@session.wait_timeout; + +SET @@session.wait_timeout = False; +SELECT @@session.wait_timeout; + + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.wait_timeout = "Test"; + + +--Error ER_WRONG_TYPE_FOR_VAR +SET @@session.wait_timeout = 'test'; + +SET @@session.wait_timeout = 123456789031; +SELECT @@session.wait_timeout = @max_wait_timeout; + + +--echo '#------------------FN_DYNVARS_005_06-----------------------#' +#################################################################### +# Check if the value in GLOBAL Table matches value in variable # +#################################################################### + +SELECT @@global.wait_timeout = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='wait_timeout'; + +--echo '#------------------FN_DYNVARS_005_07-----------------------#' +#################################################################### +# Check if the value in SESSION Table matches value in variable # +#################################################################### + +SELECT @@session.wait_timeout = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='wait_timeout'; + +--echo '#---------------------FN_DYNVARS_001_09----------------------#' +########################################################################### +# Check if global and session variable are independent of each other # +########################################################################### + +SET @@global.wait_timeout = 30000; +SET @@global.wait_timeout = 40000; +SELECT @@wait_timeout = @@global.wait_timeout; + +--echo '#---------------------FN_DYNVARS_001_10----------------------#' +######################################################################## +# Check if accessing variable with SESSION,LOCAL and without SCOPE # +# points to same session variable # +######################################################################## + +SET @@wait_timeout = 100; +SELECT @@wait_timeout = @@local.wait_timeout; +SELECT @@local.wait_timeout = @@session.wait_timeout; + +--echo '#---------------------FN_DYNVARS_001_11----------------------#' +####################################################################### +# Check if wait_timeout can be accessed with and without @@ sign # +####################################################################### + +SET wait_timeout = 1027; +SELECT @@wait_timeout; + + +--Error ER_UNKNOWN_TABLE +SELECT local.wait_timeout; + +--Error ER_UNKNOWN_TABLE +SELECT session.wait_timeout; + +--Error ER_BAD_FIELD_ERROR +SELECT wait_timeout = @@session.wait_timeout; + + +#################################### +# Restore initial value # +#################################### + +SET @@global.wait_timeout = @start_global_value; +SET @@session.wait_timeout = @start_session_value; + +################################################# +# END OF wait_timeout TESTS # +################################################# diff --git a/mysql-test/r/binlog_cache_size_basic_32.result b/mysql-test/r/binlog_cache_size_basic_32.result new file mode 100644 index 00000000000..6267c5493da --- /dev/null +++ b/mysql-test/r/binlog_cache_size_basic_32.result @@ -0,0 +1,102 @@ +SET @start_value = @@global.binlog_cache_size; +SELECT @start_value; +@start_value +32768 +'#--------------------FN_DYNVARS_006_01------------------------#' +SET @@global.binlog_cache_size = 100; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '100' +SET @@global.binlog_cache_size = DEFAULT; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +32768 +'#---------------------FN_DYNVARS_006_02-------------------------#' +SET @@global.binlog_cache_size = @start_value; +SELECT @@global.binlog_cache_size = 32768; +@@global.binlog_cache_size = 32768 +1 +'#--------------------FN_DYNVARS_006_03------------------------#' +SET @@global.binlog_cache_size = 4096; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +SET @@global.binlog_cache_size = 4294967295; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4294963200 +SET @@global.binlog_cache_size = 10000; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +8192 +SET @@global.binlog_cache_size = 21221204; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +21217280 +'Bug: Invalid values are coming in variable on assigning valid values' +'#--------------------FN_DYNVARS_006_04-------------------------#' +SET @@global.binlog_cache_size = 1024; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '1024' +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +SET @@global.binlog_cache_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'binlog_cache_size' +SET @@global.binlog_cache_size = -1024; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '0' +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +SET @@global.binlog_cache_size = 42949672950; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '42949672950' +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4294963200 +'Bug: Errors are not coming on assigning invalid values to variable' +SET @@global.binlog_cache_size = ON; +ERROR 42000: Incorrect argument type to variable 'binlog_cache_size' +SET @@global.binlog_cache_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'binlog_cache_size' +'#-------------------FN_DYNVARS_006_05----------------------------#' +SET @@session.binlog_cache_size = 0; +ERROR HY000: Variable 'binlog_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +'#----------------------FN_DYNVARS_006_06------------------------#' +SELECT @@global.binlog_cache_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='binlog_cache_size'; +@@global.binlog_cache_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_006_07----------------------#' +SET @@global.binlog_cache_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '1' +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +SET @@global.binlog_cache_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '0' +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +'Bug: Errors are not coming on assigning TRUE/FALSE to variable' +'#---------------------FN_DYNVARS_006_08----------------------#' +SET @@global.binlog_cache_size = 1; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '1' +SELECT @@binlog_cache_size = @@global.binlog_cache_size; +@@binlog_cache_size = @@global.binlog_cache_size +1 +'#---------------------FN_DYNVARS_006_09----------------------#' +SET binlog_cache_size = 1; +ERROR HY000: Variable 'binlog_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SET global.binlog_cache_size = 1; +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 'binlog_cache_size = 1' at line 1 +SELECT global.binlog_cache_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT binlog_cache_size = @@session.binlog_cache_size; +ERROR 42S22: Unknown column 'binlog_cache_size' in 'field list' +SET @@global.binlog_cache_size = @start_value; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +32768 diff --git a/mysql-test/r/binlog_cache_size_basic_64.result b/mysql-test/r/binlog_cache_size_basic_64.result new file mode 100644 index 00000000000..45ed43589a3 --- /dev/null +++ b/mysql-test/r/binlog_cache_size_basic_64.result @@ -0,0 +1,100 @@ +SET @start_value = @@global.binlog_cache_size; +SELECT @start_value; +@start_value +32768 +'#--------------------FN_DYNVARS_006_01------------------------#' +SET @@global.binlog_cache_size = 100; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '100' +SET @@global.binlog_cache_size = DEFAULT; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +32768 +'#---------------------FN_DYNVARS_006_02-------------------------#' +SET @@global.binlog_cache_size = @start_value; +SELECT @@global.binlog_cache_size = 32768; +@@global.binlog_cache_size = 32768 +1 +'#--------------------FN_DYNVARS_006_03------------------------#' +SET @@global.binlog_cache_size = 4096; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +SET @@global.binlog_cache_size = 4294967295; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4294963200 +SET @@global.binlog_cache_size = 10000; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +8192 +SET @@global.binlog_cache_size = 21221204; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +21217280 +'Bug: Invalid values are coming in variable on assigning valid values' +'#--------------------FN_DYNVARS_006_04-------------------------#' +SET @@global.binlog_cache_size = 1024; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '1024' +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +SET @@global.binlog_cache_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'binlog_cache_size' +SET @@global.binlog_cache_size = -1024; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '0' +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +SET @@global.binlog_cache_size = 42949672950; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +42949668864 +'Bug: Errors are not coming on assigning invalid values to variable' +SET @@global.binlog_cache_size = ON; +ERROR 42000: Incorrect argument type to variable 'binlog_cache_size' +SET @@global.binlog_cache_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'binlog_cache_size' +'#-------------------FN_DYNVARS_006_05----------------------------#' +SET @@session.binlog_cache_size = 0; +ERROR HY000: Variable 'binlog_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +'#----------------------FN_DYNVARS_006_06------------------------#' +SELECT @@global.binlog_cache_size = VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES WHERE VARIABLE_NAME='binlog_cache_size'; +@@global.binlog_cache_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_006_07----------------------#' +SET @@global.binlog_cache_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '1' +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +SET @@global.binlog_cache_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '0' +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +4096 +'Bug: Errors are not coming on assigning TRUE/FALSE to variable' +'#---------------------FN_DYNVARS_006_08----------------------#' +SET @@global.binlog_cache_size = 1; +Warnings: +Warning 1292 Truncated incorrect binlog_cache_size value: '1' +SELECT @@binlog_cache_size = @@global.binlog_cache_size; +@@binlog_cache_size = @@global.binlog_cache_size +1 +'#---------------------FN_DYNVARS_006_09----------------------#' +SET binlog_cache_size = 1; +ERROR HY000: Variable 'binlog_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SET global.binlog_cache_size = 1; +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 'binlog_cache_size = 1' at line 1 +SELECT global.binlog_cache_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT binlog_cache_size = @@session.binlog_cache_size; +ERROR 42S22: Unknown column 'binlog_cache_size' in 'field list' +SET @@global.binlog_cache_size = @start_value; +SELECT @@global.binlog_cache_size; +@@global.binlog_cache_size +32768 diff --git a/mysql-test/r/bulk_insert_buffer_size_basic_32.result b/mysql-test/r/bulk_insert_buffer_size_basic_32.result new file mode 100644 index 00000000000..1194a0e7ce7 --- /dev/null +++ b/mysql-test/r/bulk_insert_buffer_size_basic_32.result @@ -0,0 +1,154 @@ +SET @start_global_value = @@global.bulk_insert_buffer_size; +SELECT @start_global_value; +@start_global_value +8388608 +SET @start_session_value = @@session.bulk_insert_buffer_size; +SELECT @start_session_value; +@start_session_value +8388608 +'#--------------------FN_DYNVARS_007_01-------------------------#' +SET @@global.bulk_insert_buffer_size = 100; +SET @@global.bulk_insert_buffer_size = DEFAULT; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +8388608 +SET @@session.bulk_insert_buffer_size = 200; +SET @@session.bulk_insert_buffer_size = DEFAULT; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +8388608 +'#--------------------FN_DYNVARS_007_02-------------------------#' +SET @@global.bulk_insert_buffer_size = @start_global_value; +SELECT @@global.bulk_insert_buffer_size = 8388608; +@@global.bulk_insert_buffer_size = 8388608 +1 +SET @@session.bulk_insert_buffer_size = @start_session_value; +SELECT @@session.bulk_insert_buffer_size = 8388608; +@@session.bulk_insert_buffer_size = 8388608 +1 +'#--------------------FN_DYNVARS_007_03-------------------------#' +SET @@global.bulk_insert_buffer_size = 0; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +0 +SET @@global.bulk_insert_buffer_size = 1; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +1 +SET @@global.bulk_insert_buffer_size = 4294967295; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +4294967295 +SET @@global.bulk_insert_buffer_size = 429496; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +429496 +'#--------------------FN_DYNVARS_007_04-------------------------#' +SET @@session.bulk_insert_buffer_size = 0; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +0 +SET @@session.bulk_insert_buffer_size = 1; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +1 +SET @@session.bulk_insert_buffer_size = 4294967295; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +4294967295 +SET @@session.bulk_insert_buffer_size = 429496; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +429496 +'#------------------FN_DYNVARS_007_05-----------------------#' +SET @@global.bulk_insert_buffer_size = 42949672950; +Warnings: +Warning 1292 Truncated incorrect bulk_insert_buffer_size value: '42949672950' +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +4294967295 +SET @@global.bulk_insert_buffer_size = -1024; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +0 +SET @@global.bulk_insert_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +SET @@global.bulk_insert_buffer_size = ON; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +SET @@global.bulk_insert_buffer_size = 429496.10; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +SET @@session.bulk_insert_buffer_size = 42949672950; +Warnings: +Warning 1292 Truncated incorrect bulk_insert_buffer_size value: '42949672950' +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +4294967295 +SET @@session.bulk_insert_buffer_size = -2; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +0 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@session.bulk_insert_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +SET @@session.bulk_insert_buffer_size = 429496.10; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +'#------------------FN_DYNVARS_007_06-----------------------#' +SELECT @@global.bulk_insert_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='bulk_insert_buffer_size'; +@@global.bulk_insert_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_007_07-----------------------#' +SELECT @@session.bulk_insert_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='bulk_insert_buffer_size'; +@@session.bulk_insert_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_007_08-----------------------#' +SET @@global.bulk_insert_buffer_size = TRUE; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +1 +SET @@global.bulk_insert_buffer_size = FALSE; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +0 +SET @@session.bulk_insert_buffer_size = TRUE; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +1 +SET @@session.bulk_insert_buffer_size = FALSE; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +0 +'#---------------------FN_DYNVARS_007_09----------------------#' +SET @@bulk_insert_buffer_size = 100; +SELECT @@bulk_insert_buffer_size = @@local.bulk_insert_buffer_size; +@@bulk_insert_buffer_size = @@local.bulk_insert_buffer_size +1 +SELECT @@local.bulk_insert_buffer_size = @@session.bulk_insert_buffer_size; +@@local.bulk_insert_buffer_size = @@session.bulk_insert_buffer_size +1 +'#---------------------FN_DYNVARS_007_10----------------------#' +SET bulk_insert_buffer_size = 1; +SELECT @@bulk_insert_buffer_size; +@@bulk_insert_buffer_size +1 +SET local.bulk_insert_buffer_size = 1; +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 'bulk_insert_buffer_size = 1' at line 1 +SELECT local.bulk_insert_buffer_size; +ERROR 42S02: Unknown table 'local' in field list +SET session.bulk_insert_buffer_size = 1; +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 'bulk_insert_buffer_size = 1' at line 1 +SELECT session.bulk_insert_buffer_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT bulk_insert_buffer_size = @@session.bulk_insert_buffer_size; +ERROR 42S22: Unknown column 'bulk_insert_buffer_size' in 'field list' +SET @@global.bulk_insert_buffer_size = @start_global_value; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +8388608 +SET @@session.bulk_insert_buffer_size = @start_session_value; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +8388608 diff --git a/mysql-test/r/bulk_insert_buffer_size_basic_64.result b/mysql-test/r/bulk_insert_buffer_size_basic_64.result new file mode 100644 index 00000000000..9e0e8e07470 --- /dev/null +++ b/mysql-test/r/bulk_insert_buffer_size_basic_64.result @@ -0,0 +1,150 @@ +SET @start_global_value = @@global.bulk_insert_buffer_size; +SELECT @start_global_value; +@start_global_value +8388608 +SET @start_session_value = @@session.bulk_insert_buffer_size; +SELECT @start_session_value; +@start_session_value +8388608 +'#--------------------FN_DYNVARS_007_01-------------------------#' +SET @@global.bulk_insert_buffer_size = 100; +SET @@global.bulk_insert_buffer_size = DEFAULT; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +8388608 +SET @@session.bulk_insert_buffer_size = 200; +SET @@session.bulk_insert_buffer_size = DEFAULT; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +8388608 +'#--------------------FN_DYNVARS_007_02-------------------------#' +SET @@global.bulk_insert_buffer_size = @start_global_value; +SELECT @@global.bulk_insert_buffer_size = 8388608; +@@global.bulk_insert_buffer_size = 8388608 +1 +SET @@session.bulk_insert_buffer_size = @start_session_value; +SELECT @@session.bulk_insert_buffer_size = 8388608; +@@session.bulk_insert_buffer_size = 8388608 +1 +'#--------------------FN_DYNVARS_007_03-------------------------#' +SET @@global.bulk_insert_buffer_size = 0; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +0 +SET @@global.bulk_insert_buffer_size = 1; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +1 +SET @@global.bulk_insert_buffer_size = 4294967295; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +4294967295 +SET @@global.bulk_insert_buffer_size = 429496; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +429496 +'#--------------------FN_DYNVARS_007_04-------------------------#' +SET @@session.bulk_insert_buffer_size = 0; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +0 +SET @@session.bulk_insert_buffer_size = 1; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +1 +SET @@session.bulk_insert_buffer_size = 4294967295; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +4294967295 +SET @@session.bulk_insert_buffer_size = 429496; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +429496 +'#------------------FN_DYNVARS_007_05-----------------------#' +SET @@global.bulk_insert_buffer_size = 42949672950; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +42949672950 +SET @@global.bulk_insert_buffer_size = -1024; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +0 +SET @@global.bulk_insert_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +SET @@global.bulk_insert_buffer_size = ON; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +SET @@global.bulk_insert_buffer_size = 429496.10; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +SET @@session.bulk_insert_buffer_size = 42949672950; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +42949672950 +SET @@session.bulk_insert_buffer_size = -2; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +0 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@session.bulk_insert_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +SET @@session.bulk_insert_buffer_size = 429496.10; +ERROR 42000: Incorrect argument type to variable 'bulk_insert_buffer_size' +'#------------------FN_DYNVARS_007_06-----------------------#' +SELECT @@global.bulk_insert_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='bulk_insert_buffer_size'; +@@global.bulk_insert_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_007_07-----------------------#' +SELECT @@session.bulk_insert_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='bulk_insert_buffer_size'; +@@session.bulk_insert_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_007_08-----------------------#' +SET @@global.bulk_insert_buffer_size = TRUE; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +1 +SET @@global.bulk_insert_buffer_size = FALSE; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +0 +SET @@session.bulk_insert_buffer_size = TRUE; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +1 +SET @@session.bulk_insert_buffer_size = FALSE; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +0 +'#---------------------FN_DYNVARS_007_09----------------------#' +SET @@bulk_insert_buffer_size = 100; +SELECT @@bulk_insert_buffer_size = @@local.bulk_insert_buffer_size; +@@bulk_insert_buffer_size = @@local.bulk_insert_buffer_size +1 +SELECT @@local.bulk_insert_buffer_size = @@session.bulk_insert_buffer_size; +@@local.bulk_insert_buffer_size = @@session.bulk_insert_buffer_size +1 +'#---------------------FN_DYNVARS_007_10----------------------#' +SET bulk_insert_buffer_size = 1; +SELECT @@bulk_insert_buffer_size; +@@bulk_insert_buffer_size +1 +SET local.bulk_insert_buffer_size = 1; +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 'bulk_insert_buffer_size = 1' at line 1 +SELECT local.bulk_insert_buffer_size; +ERROR 42S02: Unknown table 'local' in field list +SET session.bulk_insert_buffer_size = 1; +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 'bulk_insert_buffer_size = 1' at line 1 +SELECT session.bulk_insert_buffer_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT bulk_insert_buffer_size = @@session.bulk_insert_buffer_size; +ERROR 42S22: Unknown column 'bulk_insert_buffer_size' in 'field list' +SET @@global.bulk_insert_buffer_size = @start_global_value; +SELECT @@global.bulk_insert_buffer_size; +@@global.bulk_insert_buffer_size +8388608 +SET @@session.bulk_insert_buffer_size = @start_session_value; +SELECT @@session.bulk_insert_buffer_size; +@@session.bulk_insert_buffer_size +8388608 diff --git a/mysql-test/r/delayed_insert_limit_basic_32.result b/mysql-test/r/delayed_insert_limit_basic_32.result new file mode 100644 index 00000000000..cb6820b2941 --- /dev/null +++ b/mysql-test/r/delayed_insert_limit_basic_32.result @@ -0,0 +1,112 @@ +SET @start_value = @@global.delayed_insert_limit; +SELECT @start_value; +@start_value +100 +'#--------------------FN_DYNVARS_024_01------------------------#' +SET @@global.delayed_insert_limit = 100; +SET @@global.delayed_insert_limit = DEFAULT; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +100 +'#---------------------FN_DYNVARS_024_02-------------------------#' +SET @@global.delayed_insert_limit = @start_value; +SELECT @@global.delayed_insert_limit = 100; +@@global.delayed_insert_limit = 100 +1 +'#--------------------FN_DYNVARS_024_03------------------------#' +SET @@global.delayed_insert_limit = 10000; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +10000 +SET @@global.delayed_insert_limit = 4294967295; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +4294967295 +SET @@global.delayed_insert_limit = 1; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +'#--------------------FN_DYNVARS_024_04-------------------------#' +SET @@global.delayed_insert_limit = 0; +Warnings: +Warning 1292 Truncated incorrect delayed_insert_limit value: '0' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +SET @@global.delayed_insert_limit = -1024; +Warnings: +Warning 1292 Truncated incorrect delayed_insert_limit value: '0' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +SET @@global.delayed_insert_limit = 42949672950; +Warnings: +Warning 1292 Truncated incorrect delayed_insert_limit value: '42949672950' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +4294967295 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.delayed_insert_limit = 429496729.5; +ERROR 42000: Incorrect argument type to variable 'delayed_insert_limit' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +4294967295 +SET @@global.delayed_insert_limit = ON; +ERROR 42000: Incorrect argument type to variable 'delayed_insert_limit' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +4294967295 +'#-------------------FN_DYNVARS_024_05----------------------------#' +SET @@session.delayed_insert_limit = 0; +ERROR HY000: Variable 'delayed_insert_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@Session.delayed_insert_limit; +ERROR HY000: Variable 'delayed_insert_limit' is a GLOBAL variable +'#----------------------FN_DYNVARS_024_06------------------------#' +SELECT @@global.delayed_insert_limit = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='delayed_insert_limit'; +@@global.delayed_insert_limit = +VARIABLE_VALUE +1 +SELECT @@delayed_insert_limit = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='delayed_insert_limit'; +@@delayed_insert_limit = +VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_024_07----------------------#' +SET @@global.delayed_insert_limit = TRUE; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +SET @@global.delayed_insert_limit = FALSE; +Warnings: +Warning 1292 Truncated incorrect delayed_insert_limit value: '0' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +'#---------------------FN_DYNVARS_024_08----------------------#' +SET @@global.delayed_insert_limit = 1; +SELECT @@delayed_insert_limit = @@global.delayed_insert_limit; +@@delayed_insert_limit = @@global.delayed_insert_limit +1 +'#---------------------FN_DYNVARS_024_09----------------------#' +SET delayed_insert_limit = 1; +ERROR HY000: Variable 'delayed_insert_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@delayed_insert_limit; +@@delayed_insert_limit +1 +SET local.delayed_insert_limit = 1; +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 'delayed_insert_limit = 1' at line 1 +SELECT local.delayed_insert_limit; +ERROR 42S02: Unknown table 'local' in field list +SET global.delayed_insert_limit = 1; +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 'delayed_insert_limit = 1' at line 1 +SELECT global.delayed_insert_limit; +ERROR 42S02: Unknown table 'global' in field list +SELECT delayed_insert_limit = @@session.delayed_insert_limit; +ERROR 42S22: Unknown column 'delayed_insert_limit' in 'field list' +SET @@global.delayed_insert_limit = @start_value; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +100 diff --git a/mysql-test/r/delayed_insert_limit_basic_64.result b/mysql-test/r/delayed_insert_limit_basic_64.result new file mode 100644 index 00000000000..246bf0e8734 --- /dev/null +++ b/mysql-test/r/delayed_insert_limit_basic_64.result @@ -0,0 +1,110 @@ +SET @start_value = @@global.delayed_insert_limit; +SELECT @start_value; +@start_value +100 +'#--------------------FN_DYNVARS_024_01------------------------#' +SET @@global.delayed_insert_limit = 100; +SET @@global.delayed_insert_limit = DEFAULT; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +100 +'#---------------------FN_DYNVARS_024_02-------------------------#' +SET @@global.delayed_insert_limit = @start_value; +SELECT @@global.delayed_insert_limit = 100; +@@global.delayed_insert_limit = 100 +1 +'#--------------------FN_DYNVARS_024_03------------------------#' +SET @@global.delayed_insert_limit = 10000; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +10000 +SET @@global.delayed_insert_limit = 4294967295; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +4294967295 +SET @@global.delayed_insert_limit = 1; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +'#--------------------FN_DYNVARS_024_04-------------------------#' +SET @@global.delayed_insert_limit = 0; +Warnings: +Warning 1292 Truncated incorrect delayed_insert_limit value: '0' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +SET @@global.delayed_insert_limit = -1024; +Warnings: +Warning 1292 Truncated incorrect delayed_insert_limit value: '0' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +SET @@global.delayed_insert_limit = 42949672950; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +42949672950 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.delayed_insert_limit = 429496729.5; +ERROR 42000: Incorrect argument type to variable 'delayed_insert_limit' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +42949672950 +SET @@global.delayed_insert_limit = ON; +ERROR 42000: Incorrect argument type to variable 'delayed_insert_limit' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +42949672950 +'#-------------------FN_DYNVARS_024_05----------------------------#' +SET @@session.delayed_insert_limit = 0; +ERROR HY000: Variable 'delayed_insert_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@Session.delayed_insert_limit; +ERROR HY000: Variable 'delayed_insert_limit' is a GLOBAL variable +'#----------------------FN_DYNVARS_024_06------------------------#' +SELECT @@global.delayed_insert_limit = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='delayed_insert_limit'; +@@global.delayed_insert_limit = +VARIABLE_VALUE +1 +SELECT @@delayed_insert_limit = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='delayed_insert_limit'; +@@delayed_insert_limit = +VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_024_07----------------------#' +SET @@global.delayed_insert_limit = TRUE; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +SET @@global.delayed_insert_limit = FALSE; +Warnings: +Warning 1292 Truncated incorrect delayed_insert_limit value: '0' +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +1 +'#---------------------FN_DYNVARS_024_08----------------------#' +SET @@global.delayed_insert_limit = 1; +SELECT @@delayed_insert_limit = @@global.delayed_insert_limit; +@@delayed_insert_limit = @@global.delayed_insert_limit +1 +'#---------------------FN_DYNVARS_024_09----------------------#' +SET delayed_insert_limit = 1; +ERROR HY000: Variable 'delayed_insert_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@delayed_insert_limit; +@@delayed_insert_limit +1 +SET local.delayed_insert_limit = 1; +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 'delayed_insert_limit = 1' at line 1 +SELECT local.delayed_insert_limit; +ERROR 42S02: Unknown table 'local' in field list +SET global.delayed_insert_limit = 1; +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 'delayed_insert_limit = 1' at line 1 +SELECT global.delayed_insert_limit; +ERROR 42S02: Unknown table 'global' in field list +SELECT delayed_insert_limit = @@session.delayed_insert_limit; +ERROR 42S22: Unknown column 'delayed_insert_limit' in 'field list' +SET @@global.delayed_insert_limit = @start_value; +SELECT @@global.delayed_insert_limit; +@@global.delayed_insert_limit +100 diff --git a/mysql-test/r/delayed_queue_size_basic_32.result b/mysql-test/r/delayed_queue_size_basic_32.result new file mode 100644 index 00000000000..6bfa6f0de40 --- /dev/null +++ b/mysql-test/r/delayed_queue_size_basic_32.result @@ -0,0 +1,110 @@ +SET @start_value = @@global.delayed_queue_size; +SELECT @start_value; +@start_value +1000 +'#--------------------FN_DYNVARS_026_01------------------------#' +SET @@global.delayed_queue_size = 100; +SET @@global.delayed_queue_size = DEFAULT; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1000 +'#---------------------FN_DYNVARS_026_02-------------------------#' +SET @@global.delayed_queue_size = @start_value; +SELECT @@global.delayed_queue_size = 1000; +@@global.delayed_queue_size = 1000 +1 +'#--------------------FN_DYNVARS_026_03------------------------#' +SET @@global.delayed_queue_size = 10000; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +10000 +SET @@global.delayed_queue_size = 4294967295; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +4294967295 +SET @@global.delayed_queue_size = 1; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +'#--------------------FN_DYNVARS_026_04-------------------------#' +SET @@global.delayed_queue_size = 0; +Warnings: +Warning 1292 Truncated incorrect delayed_queue_size value: '0' +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +SET @@global.delayed_queue_size = -1024; +Warnings: +Warning 1292 Truncated incorrect delayed_queue_size value: '0' +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +SET @@global.delayed_queue_size = 42949672950; +Warnings: +Warning 1292 Truncated incorrect delayed_queue_size value: '42949672950' +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +4294967295 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.delayed_queue_size = 429496729.5; +ERROR 42000: Incorrect argument type to variable 'delayed_queue_size' +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +4294967295 +SET @@global.delayed_queue_size = ON; +ERROR 42000: Incorrect argument type to variable 'delayed_queue_size' +SELECT @@delayed_queue_size; +@@delayed_queue_size +4294967295 +'#-------------------FN_DYNVARS_026_05----------------------------#' +SET @@session.delayed_queue_size = 0; +ERROR HY000: Variable 'delayed_queue_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.delayed_queue_size; +ERROR HY000: Variable 'delayed_queue_size' is a GLOBAL variable +'#----------------------FN_DYNVARS_026_06------------------------#' +SELECT @@global.delayed_queue_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='delayed_queue_size'; +@@global.delayed_queue_size = VARIABLE_VALUE +1 +SELECT @@delayed_queue_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='delayed_queue_size'; +@@delayed_queue_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_026_07----------------------#' +SET @@global.delayed_queue_size = TRUE; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +SET @@global.delayed_queue_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect delayed_queue_size value: '0' +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +'#---------------------FN_DYNVARS_026_08----------------------#' +SET @@global.delayed_queue_size = 1; +SELECT @@delayed_queue_size = @@global.delayed_queue_size; +@@delayed_queue_size = @@global.delayed_queue_size +1 +'#---------------------FN_DYNVARS_026_09----------------------#' +SET delayed_queue_size = 1; +ERROR HY000: Variable 'delayed_queue_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@delayed_queue_size; +@@delayed_queue_size +1 +SET local.delayed_queue_size = 1; +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 'delayed_queue_size = 1' at line 1 +SELECT local.delayed_queue_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.delayed_queue_size = 1; +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 'delayed_queue_size = 1' at line 1 +SELECT global.delayed_queue_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT delayed_queue_size = @@session.delayed_queue_size; +ERROR 42S22: Unknown column 'delayed_queue_size' in 'field list' +SET @@global.delayed_queue_size = @start_value; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1000 diff --git a/mysql-test/r/delayed_queue_size_basic_64.result b/mysql-test/r/delayed_queue_size_basic_64.result new file mode 100644 index 00000000000..d575626b0a1 --- /dev/null +++ b/mysql-test/r/delayed_queue_size_basic_64.result @@ -0,0 +1,108 @@ +SET @start_value = @@global.delayed_queue_size; +SELECT @start_value; +@start_value +1000 +'#--------------------FN_DYNVARS_026_01------------------------#' +SET @@global.delayed_queue_size = 100; +SET @@global.delayed_queue_size = DEFAULT; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1000 +'#---------------------FN_DYNVARS_026_02-------------------------#' +SET @@global.delayed_queue_size = @start_value; +SELECT @@global.delayed_queue_size = 1000; +@@global.delayed_queue_size = 1000 +1 +'#--------------------FN_DYNVARS_026_03------------------------#' +SET @@global.delayed_queue_size = 10000; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +10000 +SET @@global.delayed_queue_size = 4294967295; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +4294967295 +SET @@global.delayed_queue_size = 1; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +'#--------------------FN_DYNVARS_026_04-------------------------#' +SET @@global.delayed_queue_size = 0; +Warnings: +Warning 1292 Truncated incorrect delayed_queue_size value: '0' +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +SET @@global.delayed_queue_size = -1024; +Warnings: +Warning 1292 Truncated incorrect delayed_queue_size value: '0' +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +SET @@global.delayed_queue_size = 42949672950; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +42949672950 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.delayed_queue_size = 429496729.5; +ERROR 42000: Incorrect argument type to variable 'delayed_queue_size' +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +42949672950 +SET @@global.delayed_queue_size = ON; +ERROR 42000: Incorrect argument type to variable 'delayed_queue_size' +SELECT @@delayed_queue_size; +@@delayed_queue_size +42949672950 +'#-------------------FN_DYNVARS_026_05----------------------------#' +SET @@session.delayed_queue_size = 0; +ERROR HY000: Variable 'delayed_queue_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.delayed_queue_size; +ERROR HY000: Variable 'delayed_queue_size' is a GLOBAL variable +'#----------------------FN_DYNVARS_026_06------------------------#' +SELECT @@global.delayed_queue_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='delayed_queue_size'; +@@global.delayed_queue_size = VARIABLE_VALUE +1 +SELECT @@delayed_queue_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='delayed_queue_size'; +@@delayed_queue_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_026_07----------------------#' +SET @@global.delayed_queue_size = TRUE; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +SET @@global.delayed_queue_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect delayed_queue_size value: '0' +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1 +'#---------------------FN_DYNVARS_026_08----------------------#' +SET @@global.delayed_queue_size = 1; +SELECT @@delayed_queue_size = @@global.delayed_queue_size; +@@delayed_queue_size = @@global.delayed_queue_size +1 +'#---------------------FN_DYNVARS_026_09----------------------#' +SET delayed_queue_size = 1; +ERROR HY000: Variable 'delayed_queue_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@delayed_queue_size; +@@delayed_queue_size +1 +SET local.delayed_queue_size = 1; +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 'delayed_queue_size = 1' at line 1 +SELECT local.delayed_queue_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.delayed_queue_size = 1; +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 'delayed_queue_size = 1' at line 1 +SELECT global.delayed_queue_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT delayed_queue_size = @@session.delayed_queue_size; +ERROR 42S22: Unknown column 'delayed_queue_size' in 'field list' +SET @@global.delayed_queue_size = @start_value; +SELECT @@global.delayed_queue_size; +@@global.delayed_queue_size +1000 diff --git a/mysql-test/r/innodb_concurrency_tickets_basic_32.result b/mysql-test/r/innodb_concurrency_tickets_basic_32.result new file mode 100644 index 00000000000..1d1317d0d5e --- /dev/null +++ b/mysql-test/r/innodb_concurrency_tickets_basic_32.result @@ -0,0 +1,100 @@ +SET @global_start_value = @@global.innodb_concurrency_tickets; +SELECT @global_start_value; +@global_start_value +500 +'#--------------------FN_DYNVARS_046_01------------------------#' +SET @@global.innodb_concurrency_tickets = 0; +Warnings: +Warning 1292 Truncated incorrect concurrency_tickets value: '0' +SET @@global.innodb_concurrency_tickets = DEFAULT; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +500 +'#---------------------FN_DYNVARS_046_02-------------------------#' +SET innodb_concurrency_tickets = 1; +ERROR HY000: Variable 'innodb_concurrency_tickets' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@innodb_concurrency_tickets; +@@innodb_concurrency_tickets +500 +SELECT local.innodb_concurrency_tickets; +ERROR 42S02: Unknown table 'local' in field list +SET global innodb_concurrency_tickets = 0; +Warnings: +Warning 1292 Truncated incorrect concurrency_tickets value: '0' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1 +'#--------------------FN_DYNVARS_046_03------------------------#' +SET @@global.innodb_concurrency_tickets = 1; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1 +SET @@global.innodb_concurrency_tickets = 1000; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1000 +SET @@global.innodb_concurrency_tickets = 4294967295; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +4294967295 +'#--------------------FN_DYNVARS_046_04-------------------------#' +SET @@global.innodb_concurrency_tickets = -1; +Warnings: +Warning 1292 Truncated incorrect concurrency_tickets value: '18446744073709551615' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +4294967295 +SET @@global.innodb_concurrency_tickets = "T"; +ERROR 42000: Incorrect argument type to variable 'innodb_concurrency_tickets' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +4294967295 +SET @@global.innodb_concurrency_tickets = "Y"; +ERROR 42000: Incorrect argument type to variable 'innodb_concurrency_tickets' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +4294967295 +SET @@global.innodb_concurrency_tickets = 1001; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1001 +'#----------------------FN_DYNVARS_046_05------------------------#' +SELECT @@global.innodb_concurrency_tickets = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_concurrency_tickets'; +@@global.innodb_concurrency_tickets = +VARIABLE_VALUE +1 +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1001 +SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_concurrency_tickets'; +VARIABLE_VALUE +1001 +'#---------------------FN_DYNVARS_046_06-------------------------#' +SET @@global.innodb_concurrency_tickets = OFF; +ERROR 42000: Incorrect argument type to variable 'innodb_concurrency_tickets' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1001 +SET @@global.innodb_concurrency_tickets = ON; +ERROR 42000: Incorrect argument type to variable 'innodb_concurrency_tickets' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1001 +'#---------------------FN_DYNVARS_046_07----------------------#' +SET @@global.innodb_concurrency_tickets = TRUE; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1 +SET @@global.innodb_concurrency_tickets = FALSE; +Warnings: +Warning 1292 Truncated incorrect concurrency_tickets value: '0' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1 +SET @@global.innodb_concurrency_tickets = @global_start_value; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +500 diff --git a/mysql-test/r/innodb_concurrency_tickets_basic_64.result b/mysql-test/r/innodb_concurrency_tickets_basic_64.result new file mode 100644 index 00000000000..40d307d8733 --- /dev/null +++ b/mysql-test/r/innodb_concurrency_tickets_basic_64.result @@ -0,0 +1,98 @@ +SET @global_start_value = @@global.innodb_concurrency_tickets; +SELECT @global_start_value; +@global_start_value +500 +'#--------------------FN_DYNVARS_046_01------------------------#' +SET @@global.innodb_concurrency_tickets = 0; +Warnings: +Warning 1292 Truncated incorrect concurrency_tickets value: '0' +SET @@global.innodb_concurrency_tickets = DEFAULT; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +500 +'#---------------------FN_DYNVARS_046_02-------------------------#' +SET innodb_concurrency_tickets = 1; +ERROR HY000: Variable 'innodb_concurrency_tickets' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@innodb_concurrency_tickets; +@@innodb_concurrency_tickets +500 +SELECT local.innodb_concurrency_tickets; +ERROR 42S02: Unknown table 'local' in field list +SET global innodb_concurrency_tickets = 0; +Warnings: +Warning 1292 Truncated incorrect concurrency_tickets value: '0' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1 +'#--------------------FN_DYNVARS_046_03------------------------#' +SET @@global.innodb_concurrency_tickets = 1; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1 +SET @@global.innodb_concurrency_tickets = 1000; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1000 +SET @@global.innodb_concurrency_tickets = 4294967295; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +4294967295 +'#--------------------FN_DYNVARS_046_04-------------------------#' +SET @@global.innodb_concurrency_tickets = -1; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +18446744073709551615 +SET @@global.innodb_concurrency_tickets = "T"; +ERROR 42000: Incorrect argument type to variable 'innodb_concurrency_tickets' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +18446744073709551615 +SET @@global.innodb_concurrency_tickets = "Y"; +ERROR 42000: Incorrect argument type to variable 'innodb_concurrency_tickets' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +18446744073709551615 +SET @@global.innodb_concurrency_tickets = 1001; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1001 +'#----------------------FN_DYNVARS_046_05------------------------#' +SELECT @@global.innodb_concurrency_tickets = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_concurrency_tickets'; +@@global.innodb_concurrency_tickets = +VARIABLE_VALUE +1 +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1001 +SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_concurrency_tickets'; +VARIABLE_VALUE +1001 +'#---------------------FN_DYNVARS_046_06-------------------------#' +SET @@global.innodb_concurrency_tickets = OFF; +ERROR 42000: Incorrect argument type to variable 'innodb_concurrency_tickets' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1001 +SET @@global.innodb_concurrency_tickets = ON; +ERROR 42000: Incorrect argument type to variable 'innodb_concurrency_tickets' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1001 +'#---------------------FN_DYNVARS_046_07----------------------#' +SET @@global.innodb_concurrency_tickets = TRUE; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1 +SET @@global.innodb_concurrency_tickets = FALSE; +Warnings: +Warning 1292 Truncated incorrect concurrency_tickets value: '0' +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +1 +SET @@global.innodb_concurrency_tickets = @global_start_value; +SELECT @@global.innodb_concurrency_tickets; +@@global.innodb_concurrency_tickets +500 diff --git a/mysql-test/r/innodb_max_purge_lag_basic_32.result b/mysql-test/r/innodb_max_purge_lag_basic_32.result new file mode 100644 index 00000000000..ed960f12ff1 --- /dev/null +++ b/mysql-test/r/innodb_max_purge_lag_basic_32.result @@ -0,0 +1,94 @@ +SET @global_start_value = @@global.innodb_max_purge_lag; +SELECT @global_start_value; +@global_start_value +0 +'#--------------------FN_DYNVARS_046_01------------------------#' +SET @@global.innodb_max_purge_lag = 0; +SET @@global.innodb_max_purge_lag = DEFAULT; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 +'#---------------------FN_DYNVARS_046_02-------------------------#' +SET innodb_max_purge_lag = 1; +ERROR HY000: Variable 'innodb_max_purge_lag' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@innodb_max_purge_lag; +@@innodb_max_purge_lag +0 +SELECT local.innodb_max_purge_lag; +ERROR 42S02: Unknown table 'local' in field list +SET global innodb_max_purge_lag = 0; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 +'#--------------------FN_DYNVARS_046_03------------------------#' +SET @@global.innodb_max_purge_lag = 0; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 +SET @@global.innodb_max_purge_lag = 1; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1 +SET @@global.innodb_max_purge_lag = 4294967295; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +4294967295 +'#--------------------FN_DYNVARS_046_04-------------------------#' +SET @@global.innodb_max_purge_lag = -1; +Warnings: +Warning 1292 Truncated incorrect max_purge_lag value: '18446744073709551615' +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +4294967295 +SET @@global.innodb_max_purge_lag = "T"; +ERROR 42000: Incorrect argument type to variable 'innodb_max_purge_lag' +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +4294967295 +SET @@global.innodb_max_purge_lag = "Y"; +ERROR 42000: Incorrect argument type to variable 'innodb_max_purge_lag' +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +4294967295 +SET @@global.innodb_max_purge_lag = 1001; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1001 +'#----------------------FN_DYNVARS_046_05------------------------#' +SELECT @@global.innodb_max_purge_lag = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_max_purge_lag'; +@@global.innodb_max_purge_lag = +VARIABLE_VALUE +1 +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1001 +SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_max_purge_lag'; +VARIABLE_VALUE +1001 +'#---------------------FN_DYNVARS_046_06-------------------------#' +SET @@global.innodb_max_purge_lag = OFF; +ERROR 42000: Incorrect argument type to variable 'innodb_max_purge_lag' +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1001 +SET @@global.innodb_max_purge_lag = ON; +ERROR 42000: Incorrect argument type to variable 'innodb_max_purge_lag' +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1001 +'#---------------------FN_DYNVARS_046_07----------------------#' +SET @@global.innodb_max_purge_lag = TRUE; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1 +SET @@global.innodb_max_purge_lag = FALSE; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 +SET @@global.innodb_max_purge_lag = @global_start_value; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 diff --git a/mysql-test/r/innodb_max_purge_lag_basic_64.result b/mysql-test/r/innodb_max_purge_lag_basic_64.result new file mode 100644 index 00000000000..a6b669dde83 --- /dev/null +++ b/mysql-test/r/innodb_max_purge_lag_basic_64.result @@ -0,0 +1,92 @@ +SET @global_start_value = @@global.innodb_max_purge_lag; +SELECT @global_start_value; +@global_start_value +0 +'#--------------------FN_DYNVARS_046_01------------------------#' +SET @@global.innodb_max_purge_lag = 0; +SET @@global.innodb_max_purge_lag = DEFAULT; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 +'#---------------------FN_DYNVARS_046_02-------------------------#' +SET innodb_max_purge_lag = 1; +ERROR HY000: Variable 'innodb_max_purge_lag' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@innodb_max_purge_lag; +@@innodb_max_purge_lag +0 +SELECT local.innodb_max_purge_lag; +ERROR 42S02: Unknown table 'local' in field list +SET global innodb_max_purge_lag = 0; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 +'#--------------------FN_DYNVARS_046_03------------------------#' +SET @@global.innodb_max_purge_lag = 0; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 +SET @@global.innodb_max_purge_lag = 1; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1 +SET @@global.innodb_max_purge_lag = 4294967295; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +4294967295 +'#--------------------FN_DYNVARS_046_04-------------------------#' +SET @@global.innodb_max_purge_lag = -1; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +18446744073709551615 +SET @@global.innodb_max_purge_lag = "T"; +ERROR 42000: Incorrect argument type to variable 'innodb_max_purge_lag' +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +18446744073709551615 +SET @@global.innodb_max_purge_lag = "Y"; +ERROR 42000: Incorrect argument type to variable 'innodb_max_purge_lag' +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +18446744073709551615 +SET @@global.innodb_max_purge_lag = 1001; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1001 +'#----------------------FN_DYNVARS_046_05------------------------#' +SELECT @@global.innodb_max_purge_lag = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_max_purge_lag'; +@@global.innodb_max_purge_lag = +VARIABLE_VALUE +1 +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1001 +SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_max_purge_lag'; +VARIABLE_VALUE +1001 +'#---------------------FN_DYNVARS_046_06-------------------------#' +SET @@global.innodb_max_purge_lag = OFF; +ERROR 42000: Incorrect argument type to variable 'innodb_max_purge_lag' +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1001 +SET @@global.innodb_max_purge_lag = ON; +ERROR 42000: Incorrect argument type to variable 'innodb_max_purge_lag' +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1001 +'#---------------------FN_DYNVARS_046_07----------------------#' +SET @@global.innodb_max_purge_lag = TRUE; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +1 +SET @@global.innodb_max_purge_lag = FALSE; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 +SET @@global.innodb_max_purge_lag = @global_start_value; +SELECT @@global.innodb_max_purge_lag; +@@global.innodb_max_purge_lag +0 diff --git a/mysql-test/r/innodb_sync_spin_loops_basic_32.result b/mysql-test/r/innodb_sync_spin_loops_basic_32.result new file mode 100644 index 00000000000..2b976e65b14 --- /dev/null +++ b/mysql-test/r/innodb_sync_spin_loops_basic_32.result @@ -0,0 +1,94 @@ +SET @global_start_value = @@global.innodb_sync_spin_loops; +SELECT @global_start_value; +@global_start_value +20 +'#--------------------FN_DYNVARS_046_01------------------------#' +SET @@global.innodb_sync_spin_loops = 0; +SET @@global.innodb_sync_spin_loops = DEFAULT; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +20 +'#---------------------FN_DYNVARS_046_02-------------------------#' +SET innodb_sync_spin_loops = 1; +ERROR HY000: Variable 'innodb_sync_spin_loops' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@innodb_sync_spin_loops; +@@innodb_sync_spin_loops +20 +SELECT local.innodb_sync_spin_loops; +ERROR 42S02: Unknown table 'local' in field list +SET global innodb_sync_spin_loops = 0; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +0 +'#--------------------FN_DYNVARS_046_03------------------------#' +SET @@global.innodb_sync_spin_loops = 0; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +0 +SET @@global.innodb_sync_spin_loops = 1; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1 +SET @@global.innodb_sync_spin_loops = 1000; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1000 +'#--------------------FN_DYNVARS_046_04-------------------------#' +SET @@global.innodb_sync_spin_loops = -1; +Warnings: +Warning 1292 Truncated incorrect sync_spin_loops value: '18446744073709551615' +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +4294967295 +SET @@global.innodb_sync_spin_loops = "T"; +ERROR 42000: Incorrect argument type to variable 'innodb_sync_spin_loops' +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +4294967295 +SET @@global.innodb_sync_spin_loops = "Y"; +ERROR 42000: Incorrect argument type to variable 'innodb_sync_spin_loops' +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +4294967295 +SET @@global.innodb_sync_spin_loops = 1001; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1001 +'#----------------------FN_DYNVARS_046_05------------------------#' +SELECT @@global.innodb_sync_spin_loops = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_sync_spin_loops'; +@@global.innodb_sync_spin_loops = +VARIABLE_VALUE +1 +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1001 +SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_sync_spin_loops'; +VARIABLE_VALUE +1001 +'#---------------------FN_DYNVARS_046_06-------------------------#' +SET @@global.innodb_sync_spin_loops = OFF; +ERROR 42000: Incorrect argument type to variable 'innodb_sync_spin_loops' +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1001 +SET @@global.innodb_sync_spin_loops = ON; +ERROR 42000: Incorrect argument type to variable 'innodb_sync_spin_loops' +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1001 +'#---------------------FN_DYNVARS_046_07----------------------#' +SET @@global.innodb_sync_spin_loops = TRUE; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1 +SET @@global.innodb_sync_spin_loops = FALSE; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +0 +SET @@global.innodb_sync_spin_loops = @global_start_value; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +20 diff --git a/mysql-test/r/innodb_sync_spin_loops_basic_64.result b/mysql-test/r/innodb_sync_spin_loops_basic_64.result new file mode 100644 index 00000000000..1b99ad8e3db --- /dev/null +++ b/mysql-test/r/innodb_sync_spin_loops_basic_64.result @@ -0,0 +1,92 @@ +SET @global_start_value = @@global.innodb_sync_spin_loops; +SELECT @global_start_value; +@global_start_value +20 +'#--------------------FN_DYNVARS_046_01------------------------#' +SET @@global.innodb_sync_spin_loops = 0; +SET @@global.innodb_sync_spin_loops = DEFAULT; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +20 +'#---------------------FN_DYNVARS_046_02-------------------------#' +SET innodb_sync_spin_loops = 1; +ERROR HY000: Variable 'innodb_sync_spin_loops' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@innodb_sync_spin_loops; +@@innodb_sync_spin_loops +20 +SELECT local.innodb_sync_spin_loops; +ERROR 42S02: Unknown table 'local' in field list +SET global innodb_sync_spin_loops = 0; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +0 +'#--------------------FN_DYNVARS_046_03------------------------#' +SET @@global.innodb_sync_spin_loops = 0; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +0 +SET @@global.innodb_sync_spin_loops = 1; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1 +SET @@global.innodb_sync_spin_loops = 1000; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1000 +'#--------------------FN_DYNVARS_046_04-------------------------#' +SET @@global.innodb_sync_spin_loops = -1; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +18446744073709551615 +SET @@global.innodb_sync_spin_loops = "T"; +ERROR 42000: Incorrect argument type to variable 'innodb_sync_spin_loops' +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +18446744073709551615 +SET @@global.innodb_sync_spin_loops = "Y"; +ERROR 42000: Incorrect argument type to variable 'innodb_sync_spin_loops' +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +18446744073709551615 +SET @@global.innodb_sync_spin_loops = 1001; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1001 +'#----------------------FN_DYNVARS_046_05------------------------#' +SELECT @@global.innodb_sync_spin_loops = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_sync_spin_loops'; +@@global.innodb_sync_spin_loops = +VARIABLE_VALUE +1 +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1001 +SELECT VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='innodb_sync_spin_loops'; +VARIABLE_VALUE +1001 +'#---------------------FN_DYNVARS_046_06-------------------------#' +SET @@global.innodb_sync_spin_loops = OFF; +ERROR 42000: Incorrect argument type to variable 'innodb_sync_spin_loops' +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1001 +SET @@global.innodb_sync_spin_loops = ON; +ERROR 42000: Incorrect argument type to variable 'innodb_sync_spin_loops' +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1001 +'#---------------------FN_DYNVARS_046_07----------------------#' +SET @@global.innodb_sync_spin_loops = TRUE; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +1 +SET @@global.innodb_sync_spin_loops = FALSE; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +0 +SET @@global.innodb_sync_spin_loops = @global_start_value; +SELECT @@global.innodb_sync_spin_loops; +@@global.innodb_sync_spin_loops +20 diff --git a/mysql-test/r/join_buffer_size_basic_32.result b/mysql-test/r/join_buffer_size_basic_32.result new file mode 100644 index 00000000000..fc3061d2f59 --- /dev/null +++ b/mysql-test/r/join_buffer_size_basic_32.result @@ -0,0 +1,198 @@ +SET @start_global_value = @@global.join_buffer_size; +SELECT @start_global_value; +@start_global_value +131072 +SET @start_session_value = @@session.join_buffer_size; +SELECT @start_session_value; +@start_session_value +131072 +'#--------------------FN_DYNVARS_053_01-------------------------#' +SET @@global.join_buffer_size = 8200; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8200' +SET @@global.join_buffer_size = DEFAULT; +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +131072 +SET @@session.join_buffer_size = 8200; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8200' +SET @@session.join_buffer_size = DEFAULT; +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +131072 +'#--------------------FN_DYNVARS_053_02-------------------------#' +SET @@global.join_buffer_size = DEFAULT; +SELECT @@global.join_buffer_size = 131072; +@@global.join_buffer_size = 131072 +1 +SET @@session.join_buffer_size = DEFAULT; +SELECT @@session.join_buffer_size = 131072; +@@session.join_buffer_size = 131072 +1 +'#--------------------FN_DYNVARS_053_03-------------------------#' +SET @@global.join_buffer_size = 8200; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8200' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = 65536; +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +65536 +SET @@global.join_buffer_size = 4294967295; +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +4294963200 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +'#--------------------FN_DYNVARS_053_04-------------------------#' +SET @@session.join_buffer_size = 8200; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8200' +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +@@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228 +1 +SET @@session.join_buffer_size = 65536; +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +65536 +SET @@session.join_buffer_size = 4294967295; +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +4294963200 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +'#------------------FN_DYNVARS_053_05-----------------------#' +SET @@global.join_buffer_size = 0; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = -1024; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = 8199; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8199' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = 42949672951; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '42949672951' +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +4294963200 +SET @@global.join_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 +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +4294963200 +SET @@global.join_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'join_buffer_size' +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +4294963200 +SET @@session.join_buffer_size = 0; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +@@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228 +1 +SET @@session.join_buffer_size = -2; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +@@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228 +1 +SET @@session.join_buffer_size = 8199; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8199' +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +@@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228 +1 +SET @@session.join_buffer_size = 42949672951; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '42949672951' +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +4294963200 +SET @@session.join_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 +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +4294963200 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@session.join_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'join_buffer_size' +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +4294963200 +'#------------------FN_DYNVARS_053_06-----------------------#' +SELECT @@global.join_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='join_buffer_size'; +@@global.join_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_053_07-----------------------#' +SELECT @@session.join_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='join_buffer_size'; +@@session.join_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_053_08-----------------------#' +SET @@global.join_buffer_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '1' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +'Bug: Errors are not coming on assigning TRUE/FALSE to variable'; +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.join_buffer_size = 10; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '10' +SELECT @@join_buffer_size = @@global.join_buffer_size; +@@join_buffer_size = @@global.join_buffer_size +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@join_buffer_size = 100; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '100' +SELECT @@join_buffer_size = @@local.join_buffer_size; +@@join_buffer_size = @@local.join_buffer_size +1 +SELECT @@local.join_buffer_size = @@session.join_buffer_size; +@@local.join_buffer_size = @@session.join_buffer_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET join_buffer_size = 1; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '1' +SELECT @@join_buffer_size=8200 OR @@join_buffer_size= 8228; +@@join_buffer_size=8200 OR @@join_buffer_size= 8228 +1 +SELECT local.join_buffer_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.join_buffer_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT join_buffer_size = @@session.join_buffer_size; +ERROR 42S22: Unknown column 'join_buffer_size' in 'field list' +SET @@global.join_buffer_size = @start_global_value; +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +131072 +SET @@session.join_buffer_size = @start_session_value; +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +131072 diff --git a/mysql-test/r/join_buffer_size_basic_64.result b/mysql-test/r/join_buffer_size_basic_64.result new file mode 100644 index 00000000000..ed652af67d2 --- /dev/null +++ b/mysql-test/r/join_buffer_size_basic_64.result @@ -0,0 +1,194 @@ +SET @start_global_value = @@global.join_buffer_size; +SELECT @start_global_value; +@start_global_value +131072 +SET @start_session_value = @@session.join_buffer_size; +SELECT @start_session_value; +@start_session_value +131072 +'#--------------------FN_DYNVARS_053_01-------------------------#' +SET @@global.join_buffer_size = 8200; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8200' +SET @@global.join_buffer_size = DEFAULT; +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +131072 +SET @@session.join_buffer_size = 8200; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8200' +SET @@session.join_buffer_size = DEFAULT; +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +131072 +'#--------------------FN_DYNVARS_053_02-------------------------#' +SET @@global.join_buffer_size = DEFAULT; +SELECT @@global.join_buffer_size = 131072; +@@global.join_buffer_size = 131072 +1 +SET @@session.join_buffer_size = DEFAULT; +SELECT @@session.join_buffer_size = 131072; +@@session.join_buffer_size = 131072 +1 +'#--------------------FN_DYNVARS_053_03-------------------------#' +SET @@global.join_buffer_size = 8200; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8200' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = 65536; +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +65536 +SET @@global.join_buffer_size = 4294967295; +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +4294963200 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +'#--------------------FN_DYNVARS_053_04-------------------------#' +SET @@session.join_buffer_size = 8200; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8200' +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +@@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228 +1 +SET @@session.join_buffer_size = 65536; +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +65536 +SET @@session.join_buffer_size = 4294967295; +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +4294963200 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +'#------------------FN_DYNVARS_053_05-----------------------#' +SET @@global.join_buffer_size = 0; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = -1024; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = 8199; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8199' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = 42949672951; +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +42949668864 +SET @@global.join_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 +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +42949668864 +SET @@global.join_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'join_buffer_size' +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +42949668864 +SET @@session.join_buffer_size = 0; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +@@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228 +1 +SET @@session.join_buffer_size = -2; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +@@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228 +1 +SET @@session.join_buffer_size = 8199; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '8199' +SELECT @@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228; +@@session.join_buffer_size=8200 OR @@session.join_buffer_size= 8228 +1 +SET @@session.join_buffer_size = 42949672951; +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +42949668864 +SET @@session.join_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 +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +42949668864 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@session.join_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'join_buffer_size' +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +42949668864 +'#------------------FN_DYNVARS_053_06-----------------------#' +SELECT @@global.join_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='join_buffer_size'; +@@global.join_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_053_07-----------------------#' +SELECT @@session.join_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='join_buffer_size'; +@@session.join_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_053_08-----------------------#' +SET @@global.join_buffer_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '1' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +SET @@global.join_buffer_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '0' +SELECT @@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228; +@@global.join_buffer_size=8200 OR @@global.join_buffer_size= 8228 +1 +'Bug: Errors are not coming on assigning TRUE/FALSE to variable'; +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.join_buffer_size = 10; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '10' +SELECT @@join_buffer_size = @@global.join_buffer_size; +@@join_buffer_size = @@global.join_buffer_size +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@join_buffer_size = 100; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '100' +SELECT @@join_buffer_size = @@local.join_buffer_size; +@@join_buffer_size = @@local.join_buffer_size +1 +SELECT @@local.join_buffer_size = @@session.join_buffer_size; +@@local.join_buffer_size = @@session.join_buffer_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET join_buffer_size = 1; +Warnings: +Warning 1292 Truncated incorrect join_buffer_size value: '1' +SELECT @@join_buffer_size=8200 OR @@join_buffer_size= 8228; +@@join_buffer_size=8200 OR @@join_buffer_size= 8228 +1 +SELECT local.join_buffer_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.join_buffer_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT join_buffer_size = @@session.join_buffer_size; +ERROR 42S22: Unknown column 'join_buffer_size' in 'field list' +SET @@global.join_buffer_size = @start_global_value; +SELECT @@global.join_buffer_size; +@@global.join_buffer_size +131072 +SET @@session.join_buffer_size = @start_session_value; +SELECT @@session.join_buffer_size; +@@session.join_buffer_size +131072 diff --git a/mysql-test/r/key_buffer_size_basic_32.result b/mysql-test/r/key_buffer_size_basic_32.result new file mode 100644 index 00000000000..981988a1d4d --- /dev/null +++ b/mysql-test/r/key_buffer_size_basic_32.result @@ -0,0 +1,111 @@ +SET @start_value = @@global.key_buffer_size; +SELECT @start_value; +@start_value +1048576 +'#--------------------FN_DYNVARS_055_01------------------------#' +SET @@global.key_buffer_size = 99; +SET @@global.key_buffer_size = DEFAULT; +ERROR 42000: Variable 'key_buffer_size' doesn't have a default value +'Bug# 34878: This variable has default value according to documentation'; +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +'#---------------------FN_DYNVARS_055_02-------------------------#' +SET @@global.key_buffer_size = @start_value; +SELECT @@global.key_buffer_size = @start_value; +@@global.key_buffer_size = @start_value +1 +'#--------------------FN_DYNVARS_055_03------------------------#' +SET @@global.key_buffer_size = @min_key_buffer_size; +SELECT @@global.key_buffer_size= @min_key_buffer_size; +@@global.key_buffer_size= @min_key_buffer_size +1 +SET @@global.key_buffer_size = 1800; +Warnings: +Warning 1292 Truncated incorrect key_buffer_size value: '1800' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +SET @@global.key_buffer_size = 65535; +SELECT @@global.key_buffer_size; +@@global.key_buffer_size +61440 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +'#--------------------FN_DYNVARS_055_04-------------------------#' +SET @@global.key_buffer_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'key_buffer_size' +SELECT @@global.key_buffer_size; +@@global.key_buffer_size +61440 +SET @@global.key_buffer_size = 4; +Warnings: +Warning 1292 Truncated incorrect key_buffer_size value: '4' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.key_buffer_size = ON; +ERROR 42000: Incorrect argument type to variable 'key_buffer_size' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +SET @@global.key_buffer_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'key_buffer_size' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +'#-------------------FN_DYNVARS_055_05----------------------------#' +SET @@session.key_buffer_size = 0; +ERROR HY000: Variable 'key_buffer_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_buffer_size = @min_key_buffer_size; +@@key_buffer_size = @min_key_buffer_size +1 +'#----------------------FN_DYNVARS_055_06------------------------#' +SELECT @@global.key_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_buffer_size'; +@@global.key_buffer_size = VARIABLE_VALUE +1 +SELECT @@key_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_buffer_size'; +@@key_buffer_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_055_07----------------------#' +SET @@global.key_buffer_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect key_buffer_size value: '1' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +SET @@global.key_buffer_size = FALSE; +Warnings: +Warning 1438 Cannot drop default keycache +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +'#---------------------FN_DYNVARS_055_08----------------------#' +SET @@global.key_buffer_size = @min_key_buffer_size; +SELECT @@key_buffer_size = @@global.key_buffer_size; +@@key_buffer_size = @@global.key_buffer_size +1 +'#---------------------FN_DYNVARS_055_09----------------------#' +SET key_buffer_size = @min_key_buffer_size; +ERROR HY000: Variable 'key_buffer_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_buffer_size = @min_key_buffer_size; +@@key_buffer_size = @min_key_buffer_size +1 +SET local.key_buffer_size = 10; +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 'key_buffer_size = 10' at line 1 +SELECT local.key_buffer_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.key_buffer_size = 10; +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 'key_buffer_size = 10' at line 1 +SELECT global.key_buffer_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT key_buffer_size = @@session.key_buffer_size; +ERROR 42S22: Unknown column 'key_buffer_size' in 'field list' +SET @@global.key_buffer_size = @start_value; +SELECT @@global.key_buffer_size; +@@global.key_buffer_size +1048576 diff --git a/mysql-test/r/key_buffer_size_basic_64.result b/mysql-test/r/key_buffer_size_basic_64.result new file mode 100644 index 00000000000..981988a1d4d --- /dev/null +++ b/mysql-test/r/key_buffer_size_basic_64.result @@ -0,0 +1,111 @@ +SET @start_value = @@global.key_buffer_size; +SELECT @start_value; +@start_value +1048576 +'#--------------------FN_DYNVARS_055_01------------------------#' +SET @@global.key_buffer_size = 99; +SET @@global.key_buffer_size = DEFAULT; +ERROR 42000: Variable 'key_buffer_size' doesn't have a default value +'Bug# 34878: This variable has default value according to documentation'; +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +'#---------------------FN_DYNVARS_055_02-------------------------#' +SET @@global.key_buffer_size = @start_value; +SELECT @@global.key_buffer_size = @start_value; +@@global.key_buffer_size = @start_value +1 +'#--------------------FN_DYNVARS_055_03------------------------#' +SET @@global.key_buffer_size = @min_key_buffer_size; +SELECT @@global.key_buffer_size= @min_key_buffer_size; +@@global.key_buffer_size= @min_key_buffer_size +1 +SET @@global.key_buffer_size = 1800; +Warnings: +Warning 1292 Truncated incorrect key_buffer_size value: '1800' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +SET @@global.key_buffer_size = 65535; +SELECT @@global.key_buffer_size; +@@global.key_buffer_size +61440 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +'#--------------------FN_DYNVARS_055_04-------------------------#' +SET @@global.key_buffer_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'key_buffer_size' +SELECT @@global.key_buffer_size; +@@global.key_buffer_size +61440 +SET @@global.key_buffer_size = 4; +Warnings: +Warning 1292 Truncated incorrect key_buffer_size value: '4' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.key_buffer_size = ON; +ERROR 42000: Incorrect argument type to variable 'key_buffer_size' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +SET @@global.key_buffer_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'key_buffer_size' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +'#-------------------FN_DYNVARS_055_05----------------------------#' +SET @@session.key_buffer_size = 0; +ERROR HY000: Variable 'key_buffer_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_buffer_size = @min_key_buffer_size; +@@key_buffer_size = @min_key_buffer_size +1 +'#----------------------FN_DYNVARS_055_06------------------------#' +SELECT @@global.key_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_buffer_size'; +@@global.key_buffer_size = VARIABLE_VALUE +1 +SELECT @@key_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_buffer_size'; +@@key_buffer_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_055_07----------------------#' +SET @@global.key_buffer_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect key_buffer_size value: '1' +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +SET @@global.key_buffer_size = FALSE; +Warnings: +Warning 1438 Cannot drop default keycache +SELECT @@global.key_buffer_size = @min_key_buffer_size; +@@global.key_buffer_size = @min_key_buffer_size +1 +'#---------------------FN_DYNVARS_055_08----------------------#' +SET @@global.key_buffer_size = @min_key_buffer_size; +SELECT @@key_buffer_size = @@global.key_buffer_size; +@@key_buffer_size = @@global.key_buffer_size +1 +'#---------------------FN_DYNVARS_055_09----------------------#' +SET key_buffer_size = @min_key_buffer_size; +ERROR HY000: Variable 'key_buffer_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_buffer_size = @min_key_buffer_size; +@@key_buffer_size = @min_key_buffer_size +1 +SET local.key_buffer_size = 10; +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 'key_buffer_size = 10' at line 1 +SELECT local.key_buffer_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.key_buffer_size = 10; +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 'key_buffer_size = 10' at line 1 +SELECT global.key_buffer_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT key_buffer_size = @@session.key_buffer_size; +ERROR 42S22: Unknown column 'key_buffer_size' in 'field list' +SET @@global.key_buffer_size = @start_value; +SELECT @@global.key_buffer_size; +@@global.key_buffer_size +1048576 diff --git a/mysql-test/r/key_cache_age_threshold_basic_32.result b/mysql-test/r/key_cache_age_threshold_basic_32.result new file mode 100644 index 00000000000..023b23ea425 --- /dev/null +++ b/mysql-test/r/key_cache_age_threshold_basic_32.result @@ -0,0 +1,126 @@ +SET @start_value = @@global.key_cache_age_threshold; +SELECT @start_value; +@start_value +300 +'#--------------------FN_DYNVARS_056_01------------------------#' +SET @@global.key_cache_age_threshold = 99; +Warnings: +Warning 1292 Truncated incorrect key_cache_age_threshold value: '99' +SET @@global.key_cache_age_threshold = DEFAULT; +ERROR 42000: Variable 'key_cache_age_threshold' doesn't have a default value +'Bug# 34878: This variable has default value according to documentation'; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +'#---------------------FN_DYNVARS_056_02-------------------------#' +SET @@global.key_cache_age_threshold = @start_value; +SELECT @@global.key_cache_age_threshold = 300; +@@global.key_cache_age_threshold = 300 +1 +'#--------------------FN_DYNVARS_056_03------------------------#' +SET @@global.key_cache_age_threshold = 100; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +SET @@global.key_cache_age_threshold = 4294967295; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +4294967200 +SET @@global.key_cache_age_threshold = 1800; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +1800 +SET @@global.key_cache_age_threshold = 65535; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +65500 +'Bug# 34877 : Invalid Values are coming in variable on assigning valid values and Out Of Memory Warnings are coming'; +'#--------------------FN_DYNVARS_056_04-------------------------#' +SET @@global.key_cache_age_threshold = -1; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +4294967200 +SET @@global.key_cache_age_threshold = 42949672951; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +4294967200 +SET @@global.key_cache_age_threshold = 10000.01; +ERROR 42000: Incorrect argument type to variable 'key_cache_age_threshold' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +4294967200 +SET @@global.key_cache_age_threshold = -1024; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +4294966200 +SET @@global.key_cache_age_threshold = 99; +Warnings: +Warning 1292 Truncated incorrect key_cache_age_threshold value: '99' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.key_cache_age_threshold = ON; +ERROR 42000: Incorrect argument type to variable 'key_cache_age_threshold' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +SET @@global.key_cache_age_threshold = 'test'; +ERROR 42000: Incorrect argument type to variable 'key_cache_age_threshold' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +'#-------------------FN_DYNVARS_056_05----------------------------#' +SET @@session.key_cache_age_threshold = 0; +ERROR HY000: Variable 'key_cache_age_threshold' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.key_cache_age_threshold; +ERROR HY000: Variable 'key_cache_age_threshold' is a GLOBAL variable +'#----------------------FN_DYNVARS_056_06------------------------#' +SELECT @@global.key_cache_age_threshold = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_cache_age_threshold'; +@@global.key_cache_age_threshold = VARIABLE_VALUE +1 +SELECT @@key_cache_age_threshold = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_cache_age_threshold'; +@@key_cache_age_threshold = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_056_07----------------------#' +SET @@global.key_cache_age_threshold = TRUE; +Warnings: +Warning 1292 Truncated incorrect key_cache_age_threshold value: '1' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +SET @@global.key_cache_age_threshold = FALSE; +Warnings: +Warning 1292 Truncated incorrect key_cache_age_threshold value: '0' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +'#---------------------FN_DYNVARS_056_08----------------------#' +SET @@global.key_cache_age_threshold = 101; +SELECT @@key_cache_age_threshold = @@global.key_cache_age_threshold; +@@key_cache_age_threshold = @@global.key_cache_age_threshold +1 +'#---------------------FN_DYNVARS_056_09----------------------#' +SET key_cache_age_threshold = 8000; +ERROR HY000: Variable 'key_cache_age_threshold' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_cache_age_threshold; +@@key_cache_age_threshold +100 +SET local.key_cache_age_threshold = 10; +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 'key_cache_age_threshold = 10' at line 1 +SELECT local.key_cache_age_threshold; +ERROR 42S02: Unknown table 'local' in field list +SET global.key_cache_age_threshold = 10; +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 'key_cache_age_threshold = 10' at line 1 +SELECT global.key_cache_age_threshold; +ERROR 42S02: Unknown table 'global' in field list +SELECT key_cache_age_threshold = @@session.key_cache_age_threshold; +ERROR 42S22: Unknown column 'key_cache_age_threshold' in 'field list' +SET @@global.key_cache_age_threshold = @start_value; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +300 diff --git a/mysql-test/r/key_cache_age_threshold_basic_64.result b/mysql-test/r/key_cache_age_threshold_basic_64.result new file mode 100644 index 00000000000..5e05dd7bacf --- /dev/null +++ b/mysql-test/r/key_cache_age_threshold_basic_64.result @@ -0,0 +1,126 @@ +SET @start_value = @@global.key_cache_age_threshold; +SELECT @start_value; +@start_value +300 +'#--------------------FN_DYNVARS_056_01------------------------#' +SET @@global.key_cache_age_threshold = 99; +Warnings: +Warning 1292 Truncated incorrect key_cache_age_threshold value: '99' +SET @@global.key_cache_age_threshold = DEFAULT; +ERROR 42000: Variable 'key_cache_age_threshold' doesn't have a default value +'Bug# 34878: This variable has default value according to documentation'; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +'#---------------------FN_DYNVARS_056_02-------------------------#' +SET @@global.key_cache_age_threshold = @start_value; +SELECT @@global.key_cache_age_threshold = 300; +@@global.key_cache_age_threshold = 300 +1 +'#--------------------FN_DYNVARS_056_03------------------------#' +SET @@global.key_cache_age_threshold = 100; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +SET @@global.key_cache_age_threshold = 4294967295; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +4294967200 +SET @@global.key_cache_age_threshold = 1800; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +1800 +SET @@global.key_cache_age_threshold = 65535; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +65500 +'Bug# 34877 : Invalid Values are coming in variable on assigning valid values and Out Of Memory Warnings are coming'; +'#--------------------FN_DYNVARS_056_04-------------------------#' +SET @@global.key_cache_age_threshold = -1; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +18446744073709551600 +SET @@global.key_cache_age_threshold = 42949672951; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +42949672900 +SET @@global.key_cache_age_threshold = 10000.01; +ERROR 42000: Incorrect argument type to variable 'key_cache_age_threshold' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +42949672900 +SET @@global.key_cache_age_threshold = -1024; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +18446744073709550500 +SET @@global.key_cache_age_threshold = 99; +Warnings: +Warning 1292 Truncated incorrect key_cache_age_threshold value: '99' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.key_cache_age_threshold = ON; +ERROR 42000: Incorrect argument type to variable 'key_cache_age_threshold' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +SET @@global.key_cache_age_threshold = 'test'; +ERROR 42000: Incorrect argument type to variable 'key_cache_age_threshold' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +'#-------------------FN_DYNVARS_056_05----------------------------#' +SET @@session.key_cache_age_threshold = 0; +ERROR HY000: Variable 'key_cache_age_threshold' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.key_cache_age_threshold; +ERROR HY000: Variable 'key_cache_age_threshold' is a GLOBAL variable +'#----------------------FN_DYNVARS_056_06------------------------#' +SELECT @@global.key_cache_age_threshold = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_cache_age_threshold'; +@@global.key_cache_age_threshold = VARIABLE_VALUE +1 +SELECT @@key_cache_age_threshold = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_cache_age_threshold'; +@@key_cache_age_threshold = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_056_07----------------------#' +SET @@global.key_cache_age_threshold = TRUE; +Warnings: +Warning 1292 Truncated incorrect key_cache_age_threshold value: '1' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +SET @@global.key_cache_age_threshold = FALSE; +Warnings: +Warning 1292 Truncated incorrect key_cache_age_threshold value: '0' +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +100 +'#---------------------FN_DYNVARS_056_08----------------------#' +SET @@global.key_cache_age_threshold = 101; +SELECT @@key_cache_age_threshold = @@global.key_cache_age_threshold; +@@key_cache_age_threshold = @@global.key_cache_age_threshold +1 +'#---------------------FN_DYNVARS_056_09----------------------#' +SET key_cache_age_threshold = 8000; +ERROR HY000: Variable 'key_cache_age_threshold' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_cache_age_threshold; +@@key_cache_age_threshold +100 +SET local.key_cache_age_threshold = 10; +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 'key_cache_age_threshold = 10' at line 1 +SELECT local.key_cache_age_threshold; +ERROR 42S02: Unknown table 'local' in field list +SET global.key_cache_age_threshold = 10; +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 'key_cache_age_threshold = 10' at line 1 +SELECT global.key_cache_age_threshold; +ERROR 42S02: Unknown table 'global' in field list +SELECT key_cache_age_threshold = @@session.key_cache_age_threshold; +ERROR 42S22: Unknown column 'key_cache_age_threshold' in 'field list' +SET @@global.key_cache_age_threshold = @start_value; +SELECT @@global.key_cache_age_threshold; +@@global.key_cache_age_threshold +300 diff --git a/mysql-test/r/key_cache_block_size_basic_32.result b/mysql-test/r/key_cache_block_size_basic_32.result new file mode 100644 index 00000000000..ac78acb8244 --- /dev/null +++ b/mysql-test/r/key_cache_block_size_basic_32.result @@ -0,0 +1,142 @@ +SET @start_value = @@global.key_cache_block_size; +SELECT @start_value; +@start_value +1024 +'#--------------------FN_DYNVARS_057_01------------------------#' +SET @@global.key_cache_block_size = 600; +SET @@global.key_cache_block_size = DEFAULT; +ERROR 42000: Variable 'key_cache_block_size' doesn't have a default value +'Bug# 34877 : Invalid Values are coming in variable on assigning valid values and Out Of Memory Warnings are coming'; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +'#---------------------FN_DYNVARS_057_02-------------------------#' +SET @@global.key_cache_block_size = @start_value; +SELECT @@global.key_cache_block_size = 1024; +@@global.key_cache_block_size = 1024 +1 +'#--------------------FN_DYNVARS_057_03------------------------#' +SET @@global.key_cache_block_size = 1024; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +1024 +SET @@global.key_cache_block_size = 16384; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 1800; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +1536 +SET @@global.key_cache_block_size = 16383; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +15872 +'Bug# 34877 : Invalid Values are coming in variable on assigning valid values and Out Of Memory Warnings are coming'; +'#--------------------FN_DYNVARS_057_04-------------------------#' +SET @@global.key_cache_block_size = -1; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '4294967295' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 42949672951; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '4294967287' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'key_cache_block_size' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = -1024; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '4294966272' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 256; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '256' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +SET @@global.key_cache_block_size = 511; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '511' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +SET @@global.key_cache_block_size = 16385; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '16385' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.key_cache_block_size = ON; +ERROR 42000: Incorrect argument type to variable 'key_cache_block_size' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'key_cache_block_size' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +'#-------------------FN_DYNVARS_057_05----------------------------#' +SET @@session.key_cache_block_size = 0; +ERROR HY000: Variable 'key_cache_block_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.key_cache_block_size; +ERROR HY000: Variable 'key_cache_block_size' is a GLOBAL variable +'#----------------------FN_DYNVARS_057_06------------------------#' +SELECT @@global.key_cache_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_cache_block_size'; +@@global.key_cache_block_size = VARIABLE_VALUE +1 +SELECT @@key_cache_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_cache_block_size'; +@@key_cache_block_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_057_07----------------------#' +SET @@global.key_cache_block_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '1' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +SET @@global.key_cache_block_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '0' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +'#---------------------FN_DYNVARS_057_08----------------------#' +SET @@global.key_cache_block_size = 1024; +SELECT @@key_cache_block_size = @@global.key_cache_block_size; +@@key_cache_block_size = @@global.key_cache_block_size +1 +'#---------------------FN_DYNVARS_057_09----------------------#' +SET key_cache_block_size = 8000; +ERROR HY000: Variable 'key_cache_block_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_cache_block_size; +@@key_cache_block_size +1024 +SET local.key_cache_block_size = 10; +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 'key_cache_block_size = 10' at line 1 +SELECT local.key_cache_block_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.key_cache_block_size = 10; +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 'key_cache_block_size = 10' at line 1 +SELECT global.key_cache_block_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT key_cache_block_size = @@session.key_cache_block_size; +ERROR 42S22: Unknown column 'key_cache_block_size' in 'field list' +SET @@global.key_cache_block_size = @start_value; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +1024 diff --git a/mysql-test/r/key_cache_block_size_basic_64.result b/mysql-test/r/key_cache_block_size_basic_64.result new file mode 100644 index 00000000000..46ce1f26b29 --- /dev/null +++ b/mysql-test/r/key_cache_block_size_basic_64.result @@ -0,0 +1,142 @@ +SET @start_value = @@global.key_cache_block_size; +SELECT @start_value; +@start_value +1024 +'#--------------------FN_DYNVARS_057_01------------------------#' +SET @@global.key_cache_block_size = 600; +SET @@global.key_cache_block_size = DEFAULT; +ERROR 42000: Variable 'key_cache_block_size' doesn't have a default value +'Bug# 34877 : Invalid Values are coming in variable on assigning valid values and Out Of Memory Warnings are coming'; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +'#---------------------FN_DYNVARS_057_02-------------------------#' +SET @@global.key_cache_block_size = @start_value; +SELECT @@global.key_cache_block_size = 1024; +@@global.key_cache_block_size = 1024 +1 +'#--------------------FN_DYNVARS_057_03------------------------#' +SET @@global.key_cache_block_size = 1024; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +1024 +SET @@global.key_cache_block_size = 16384; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 1800; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +1536 +SET @@global.key_cache_block_size = 16383; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +15872 +'Bug# 34877 : Invalid Values are coming in variable on assigning valid values and Out Of Memory Warnings are coming'; +'#--------------------FN_DYNVARS_057_04-------------------------#' +SET @@global.key_cache_block_size = -1; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '18446744073709551615' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 42949672951; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '42949672951' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'key_cache_block_size' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = -1024; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '18446744073709550592' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 256; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '256' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +SET @@global.key_cache_block_size = 511; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '511' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +SET @@global.key_cache_block_size = 16385; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '16385' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.key_cache_block_size = ON; +ERROR 42000: Incorrect argument type to variable 'key_cache_block_size' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +SET @@global.key_cache_block_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'key_cache_block_size' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +16384 +'#-------------------FN_DYNVARS_057_05----------------------------#' +SET @@session.key_cache_block_size = 0; +ERROR HY000: Variable 'key_cache_block_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.key_cache_block_size; +ERROR HY000: Variable 'key_cache_block_size' is a GLOBAL variable +'#----------------------FN_DYNVARS_057_06------------------------#' +SELECT @@global.key_cache_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_cache_block_size'; +@@global.key_cache_block_size = VARIABLE_VALUE +1 +SELECT @@key_cache_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_cache_block_size'; +@@key_cache_block_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_057_07----------------------#' +SET @@global.key_cache_block_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '1' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +SET @@global.key_cache_block_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect key_cache_block_size value: '0' +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +512 +'#---------------------FN_DYNVARS_057_08----------------------#' +SET @@global.key_cache_block_size = 1024; +SELECT @@key_cache_block_size = @@global.key_cache_block_size; +@@key_cache_block_size = @@global.key_cache_block_size +1 +'#---------------------FN_DYNVARS_057_09----------------------#' +SET key_cache_block_size = 8000; +ERROR HY000: Variable 'key_cache_block_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_cache_block_size; +@@key_cache_block_size +1024 +SET local.key_cache_block_size = 10; +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 'key_cache_block_size = 10' at line 1 +SELECT local.key_cache_block_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.key_cache_block_size = 10; +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 'key_cache_block_size = 10' at line 1 +SELECT global.key_cache_block_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT key_cache_block_size = @@session.key_cache_block_size; +ERROR 42S22: Unknown column 'key_cache_block_size' in 'field list' +SET @@global.key_cache_block_size = @start_value; +SELECT @@global.key_cache_block_size; +@@global.key_cache_block_size +1024 diff --git a/mysql-test/r/key_cache_division_limit_basic_32.result b/mysql-test/r/key_cache_division_limit_basic_32.result new file mode 100644 index 00000000000..5902dbcdf89 --- /dev/null +++ b/mysql-test/r/key_cache_division_limit_basic_32.result @@ -0,0 +1,139 @@ +SET @start_value = @@global.key_cache_division_limit; +SELECT @start_value; +@start_value +100 +'#--------------------FN_DYNVARS_058_01------------------------#' +SET @@global.key_cache_division_limit = 50; +SET @@global.key_cache_division_limit = DEFAULT; +ERROR 42000: Variable 'key_cache_division_limit' doesn't have a default value +'Bug# 34878: This variable has default value according to documentation'; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +50 +'#---------------------FN_DYNVARS_058_02-------------------------#' +SET @@global.key_cache_division_limit = @start_value; +SELECT @@global.key_cache_division_limit = 100; +@@global.key_cache_division_limit = 100 +1 +'#--------------------FN_DYNVARS_058_03------------------------#' +SET @@global.key_cache_division_limit = 1; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +1 +SET @@global.key_cache_division_limit = 50; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +50 +SET @@global.key_cache_division_limit = 99; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +99 +SET @@global.key_cache_division_limit = 2; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +2 +'#--------------------FN_DYNVARS_058_04-------------------------#' +SET @@global.key_cache_division_limit = -1; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '4294967295' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 101; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '101' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 10000.01; +ERROR 42000: Incorrect argument type to variable 'key_cache_division_limit' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = -1024; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '4294966272' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 0; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '0' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +1 +SET @@global.key_cache_division_limit = 200; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '200' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 65535; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '65535' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.key_cache_division_limit = ON; +ERROR 42000: Incorrect argument type to variable 'key_cache_division_limit' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 'test'; +ERROR 42000: Incorrect argument type to variable 'key_cache_division_limit' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +'#-------------------FN_DYNVARS_058_05----------------------------#' +SET @@session.key_cache_division_limit = 0; +ERROR HY000: Variable 'key_cache_division_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.key_cache_division_limit; +ERROR HY000: Variable 'key_cache_division_limit' is a GLOBAL variable +'#----------------------FN_DYNVARS_058_06------------------------#' +SELECT @@global.key_cache_division_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_cache_division_limit'; +@@global.key_cache_division_limit = VARIABLE_VALUE +1 +SELECT @@key_cache_division_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_cache_division_limit'; +@@key_cache_division_limit = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_058_07----------------------#' +SET @@global.key_cache_division_limit = TRUE; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +1 +SET @@global.key_cache_division_limit = FALSE; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '0' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +1 +'#---------------------FN_DYNVARS_058_08----------------------#' +SET @@global.key_cache_division_limit = 90; +SELECT @@key_cache_division_limit = @@global.key_cache_division_limit; +@@key_cache_division_limit = @@global.key_cache_division_limit +1 +'#---------------------FN_DYNVARS_058_09----------------------#' +SET key_cache_division_limit = 80; +ERROR HY000: Variable 'key_cache_division_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_cache_division_limit; +@@key_cache_division_limit +90 +SET local.key_cache_division_limit = 10; +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 'key_cache_division_limit = 10' at line 1 +SELECT local.key_cache_division_limit; +ERROR 42S02: Unknown table 'local' in field list +SET global.key_cache_division_limit = 10; +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 'key_cache_division_limit = 10' at line 1 +SELECT global.key_cache_division_limit; +ERROR 42S02: Unknown table 'global' in field list +SELECT key_cache_division_limit = @@session.key_cache_division_limit; +ERROR 42S22: Unknown column 'key_cache_division_limit' in 'field list' +SET @@global.key_cache_division_limit = @start_value; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 diff --git a/mysql-test/r/key_cache_division_limit_basic_64.result b/mysql-test/r/key_cache_division_limit_basic_64.result new file mode 100644 index 00000000000..cd0cdcbca05 --- /dev/null +++ b/mysql-test/r/key_cache_division_limit_basic_64.result @@ -0,0 +1,139 @@ +SET @start_value = @@global.key_cache_division_limit; +SELECT @start_value; +@start_value +100 +'#--------------------FN_DYNVARS_058_01------------------------#' +SET @@global.key_cache_division_limit = 50; +SET @@global.key_cache_division_limit = DEFAULT; +ERROR 42000: Variable 'key_cache_division_limit' doesn't have a default value +'Bug# 34878: This variable has default value according to documentation'; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +50 +'#---------------------FN_DYNVARS_058_02-------------------------#' +SET @@global.key_cache_division_limit = @start_value; +SELECT @@global.key_cache_division_limit = 100; +@@global.key_cache_division_limit = 100 +1 +'#--------------------FN_DYNVARS_058_03------------------------#' +SET @@global.key_cache_division_limit = 1; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +1 +SET @@global.key_cache_division_limit = 50; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +50 +SET @@global.key_cache_division_limit = 99; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +99 +SET @@global.key_cache_division_limit = 2; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +2 +'#--------------------FN_DYNVARS_058_04-------------------------#' +SET @@global.key_cache_division_limit = -1; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '18446744073709551615' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 101; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '101' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 10000.01; +ERROR 42000: Incorrect argument type to variable 'key_cache_division_limit' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = -1024; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '18446744073709550592' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 0; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '0' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +1 +SET @@global.key_cache_division_limit = 200; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '200' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 65535; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '65535' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +'Bug # 34837: Errors are not coming on assigning invalid values to variable' +SET @@global.key_cache_division_limit = ON; +ERROR 42000: Incorrect argument type to variable 'key_cache_division_limit' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +SET @@global.key_cache_division_limit = 'test'; +ERROR 42000: Incorrect argument type to variable 'key_cache_division_limit' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 +'#-------------------FN_DYNVARS_058_05----------------------------#' +SET @@session.key_cache_division_limit = 0; +ERROR HY000: Variable 'key_cache_division_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.key_cache_division_limit; +ERROR HY000: Variable 'key_cache_division_limit' is a GLOBAL variable +'#----------------------FN_DYNVARS_058_06------------------------#' +SELECT @@global.key_cache_division_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='key_cache_division_limit'; +@@global.key_cache_division_limit = VARIABLE_VALUE +1 +SELECT @@key_cache_division_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='key_cache_division_limit'; +@@key_cache_division_limit = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_058_07----------------------#' +SET @@global.key_cache_division_limit = TRUE; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +1 +SET @@global.key_cache_division_limit = FALSE; +Warnings: +Warning 1292 Truncated incorrect key_cache_division_limit value: '0' +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +1 +'#---------------------FN_DYNVARS_058_08----------------------#' +SET @@global.key_cache_division_limit = 90; +SELECT @@key_cache_division_limit = @@global.key_cache_division_limit; +@@key_cache_division_limit = @@global.key_cache_division_limit +1 +'#---------------------FN_DYNVARS_058_09----------------------#' +SET key_cache_division_limit = 80; +ERROR HY000: Variable 'key_cache_division_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@key_cache_division_limit; +@@key_cache_division_limit +90 +SET local.key_cache_division_limit = 10; +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 'key_cache_division_limit = 10' at line 1 +SELECT local.key_cache_division_limit; +ERROR 42S02: Unknown table 'local' in field list +SET global.key_cache_division_limit = 10; +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 'key_cache_division_limit = 10' at line 1 +SELECT global.key_cache_division_limit; +ERROR 42S02: Unknown table 'global' in field list +SELECT key_cache_division_limit = @@session.key_cache_division_limit; +ERROR 42S22: Unknown column 'key_cache_division_limit' in 'field list' +SET @@global.key_cache_division_limit = @start_value; +SELECT @@global.key_cache_division_limit; +@@global.key_cache_division_limit +100 diff --git a/mysql-test/r/log_warnings_basic_32.result b/mysql-test/r/log_warnings_basic_32.result new file mode 100644 index 00000000000..702e95b1383 --- /dev/null +++ b/mysql-test/r/log_warnings_basic_32.result @@ -0,0 +1,162 @@ +SET @start_global_value = @@global.log_warnings; +SELECT @start_global_value; +@start_global_value +1 +SET @start_session_value = @@session.log_warnings; +SELECT @start_session_value; +@start_session_value +1 +'#--------------------FN_DYNVARS_067_01-------------------------#' +SET @@global.log_warnings = 100; +SET @@global.log_warnings = DEFAULT; +SELECT @@global.log_warnings; +@@global.log_warnings +1 +SET @@session.log_warnings = 200; +SET @@session.log_warnings = DEFAULT; +SELECT @@session.log_warnings; +@@session.log_warnings +1 +'#--------------------FN_DYNVARS_067_02-------------------------#' +SET @@global.log_warnings = DEFAULT; +SELECT @@global.log_warnings = 1; +@@global.log_warnings = 1 +1 +SET @@session.log_warnings = DEFAULT; +SELECT @@session.log_warnings = 1; +@@session.log_warnings = 1 +1 +'#--------------------FN_DYNVARS_067_03-------------------------#' +SET @@global.log_warnings = 0; +SELECT @@global.log_warnings; +@@global.log_warnings +0 +SET @@global.log_warnings = 1; +SELECT @@global.log_warnings; +@@global.log_warnings +1 +SET @@global.log_warnings = 60020; +SELECT @@global.log_warnings; +@@global.log_warnings +60020 +SET @@global.log_warnings = 65535; +SELECT @@global.log_warnings; +@@global.log_warnings +65535 +SET @@global.log_warnings = 65536; +SELECT @@global.log_warnings; +@@global.log_warnings +65536 +'#--------------------FN_DYNVARS_067_04-------------------------#' +SET @@session.log_warnings = 0; +SELECT @@session.log_warnings; +@@session.log_warnings +0 +SET @@session.log_warnings = 1; +SELECT @@session.log_warnings; +@@session.log_warnings +1 +SET @@session.log_warnings = 50050; +SELECT @@session.log_warnings; +@@session.log_warnings +50050 +SET @@session.log_warnings = 65535; +SELECT @@session.log_warnings; +@@session.log_warnings +65535 +SET @@session.log_warnings = 65550; +SELECT @@session.log_warnings; +@@session.log_warnings +65550 +'#------------------FN_DYNVARS_067_05-----------------------#' +SET @@global.log_warnings = 100000000000; +Warnings: +Warning 1292 Truncated incorrect log-warnings value: '100000000000' +SELECT @@global.log_warnings; +@@global.log_warnings +4294967295 +SET @@global.log_warnings = -1024; +SELECT @@global.log_warnings; +@@global.log_warnings +0 +SET @@global.log_warnings = 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 +SELECT @@global.log_warnings; +@@global.log_warnings +0 +SET @@global.log_warnings = test; +ERROR 42000: Incorrect argument type to variable 'log_warnings' +SELECT @@global.log_warnings; +@@global.log_warnings +0 +SET @@session.log_warnings = 100000000000; +Warnings: +Warning 1292 Truncated incorrect log-warnings value: '100000000000' +SELECT @@session.log_warnings; +@@session.log_warnings +4294967295 +SET @@session.log_warnings = -2; +SELECT @@session.log_warnings; +@@session.log_warnings +0 +SET @@session.log_warnings = 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 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.log_warnings = test; +ERROR 42000: Incorrect argument type to variable 'log_warnings' +SELECT @@session.log_warnings; +@@session.log_warnings +0 +'#------------------FN_DYNVARS_067_06-----------------------#' +SELECT @@global.log_warnings = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_warnings'; +@@global.log_warnings = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_067_07-----------------------#' +SELECT @@session.log_warnings = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='log_warnings'; +@@session.log_warnings = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_067_08-----------------------#' +SET @@global.log_warnings = TRUE; +SELECT @@global.log_warnings; +@@global.log_warnings +1 +SET @@global.log_warnings = FALSE; +SELECT @@global.log_warnings; +@@global.log_warnings +0 +'#---------------------FN_DYNVARS_067_09----------------------#' +SET @@global.log_warnings = 10; +SELECT @@log_warnings = @@global.log_warnings; +@@log_warnings = @@global.log_warnings +0 +'#---------------------FN_DYNVARS_067_10----------------------#' +SET @@log_warnings = 100; +SELECT @@log_warnings = @@local.log_warnings; +@@log_warnings = @@local.log_warnings +1 +SELECT @@local.log_warnings = @@session.log_warnings; +@@local.log_warnings = @@session.log_warnings +1 +'#---------------------FN_DYNVARS_067_11----------------------#' +SET log_warnings = 1; +SELECT @@log_warnings; +@@log_warnings +1 +SELECT local.log_warnings; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.log_warnings; +ERROR 42S02: Unknown table 'session' in field list +SELECT log_warnings = @@session.log_warnings; +ERROR 42S22: Unknown column 'log_warnings' in 'field list' +SET @@global.log_warnings = @start_global_value; +SELECT @@global.log_warnings; +@@global.log_warnings +1 +SET @@session.log_warnings = @start_session_value; +SELECT @@session.log_warnings; +@@session.log_warnings +1 diff --git a/mysql-test/r/log_warnings_basic_64.result b/mysql-test/r/log_warnings_basic_64.result new file mode 100644 index 00000000000..ba6671c87a4 --- /dev/null +++ b/mysql-test/r/log_warnings_basic_64.result @@ -0,0 +1,158 @@ +SET @start_global_value = @@global.log_warnings; +SELECT @start_global_value; +@start_global_value +1 +SET @start_session_value = @@session.log_warnings; +SELECT @start_session_value; +@start_session_value +1 +'#--------------------FN_DYNVARS_067_01-------------------------#' +SET @@global.log_warnings = 100; +SET @@global.log_warnings = DEFAULT; +SELECT @@global.log_warnings; +@@global.log_warnings +1 +SET @@session.log_warnings = 200; +SET @@session.log_warnings = DEFAULT; +SELECT @@session.log_warnings; +@@session.log_warnings +1 +'#--------------------FN_DYNVARS_067_02-------------------------#' +SET @@global.log_warnings = DEFAULT; +SELECT @@global.log_warnings = 1; +@@global.log_warnings = 1 +1 +SET @@session.log_warnings = DEFAULT; +SELECT @@session.log_warnings = 1; +@@session.log_warnings = 1 +1 +'#--------------------FN_DYNVARS_067_03-------------------------#' +SET @@global.log_warnings = 0; +SELECT @@global.log_warnings; +@@global.log_warnings +0 +SET @@global.log_warnings = 1; +SELECT @@global.log_warnings; +@@global.log_warnings +1 +SET @@global.log_warnings = 60020; +SELECT @@global.log_warnings; +@@global.log_warnings +60020 +SET @@global.log_warnings = 65535; +SELECT @@global.log_warnings; +@@global.log_warnings +65535 +SET @@global.log_warnings = 65536; +SELECT @@global.log_warnings; +@@global.log_warnings +65536 +'#--------------------FN_DYNVARS_067_04-------------------------#' +SET @@session.log_warnings = 0; +SELECT @@session.log_warnings; +@@session.log_warnings +0 +SET @@session.log_warnings = 1; +SELECT @@session.log_warnings; +@@session.log_warnings +1 +SET @@session.log_warnings = 50050; +SELECT @@session.log_warnings; +@@session.log_warnings +50050 +SET @@session.log_warnings = 65535; +SELECT @@session.log_warnings; +@@session.log_warnings +65535 +SET @@session.log_warnings = 65550; +SELECT @@session.log_warnings; +@@session.log_warnings +65550 +'#------------------FN_DYNVARS_067_05-----------------------#' +SET @@global.log_warnings = 100000000000; +SELECT @@global.log_warnings; +@@global.log_warnings +100000000000 +SET @@global.log_warnings = -1024; +SELECT @@global.log_warnings; +@@global.log_warnings +0 +SET @@global.log_warnings = 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 +SELECT @@global.log_warnings; +@@global.log_warnings +0 +SET @@global.log_warnings = test; +ERROR 42000: Incorrect argument type to variable 'log_warnings' +SELECT @@global.log_warnings; +@@global.log_warnings +0 +SET @@session.log_warnings = 100000000000; +SELECT @@session.log_warnings; +@@session.log_warnings +100000000000 +SET @@session.log_warnings = -2; +SELECT @@session.log_warnings; +@@session.log_warnings +0 +SET @@session.log_warnings = 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 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.log_warnings = test; +ERROR 42000: Incorrect argument type to variable 'log_warnings' +SELECT @@session.log_warnings; +@@session.log_warnings +0 +'#------------------FN_DYNVARS_067_06-----------------------#' +SELECT @@global.log_warnings = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='log_warnings'; +@@global.log_warnings = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_067_07-----------------------#' +SELECT @@session.log_warnings = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='log_warnings'; +@@session.log_warnings = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_067_08-----------------------#' +SET @@global.log_warnings = TRUE; +SELECT @@global.log_warnings; +@@global.log_warnings +1 +SET @@global.log_warnings = FALSE; +SELECT @@global.log_warnings; +@@global.log_warnings +0 +'#---------------------FN_DYNVARS_067_09----------------------#' +SET @@global.log_warnings = 10; +SELECT @@log_warnings = @@global.log_warnings; +@@log_warnings = @@global.log_warnings +0 +'#---------------------FN_DYNVARS_067_10----------------------#' +SET @@log_warnings = 100; +SELECT @@log_warnings = @@local.log_warnings; +@@log_warnings = @@local.log_warnings +1 +SELECT @@local.log_warnings = @@session.log_warnings; +@@local.log_warnings = @@session.log_warnings +1 +'#---------------------FN_DYNVARS_067_11----------------------#' +SET log_warnings = 1; +SELECT @@log_warnings; +@@log_warnings +1 +SELECT local.log_warnings; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.log_warnings; +ERROR 42S02: Unknown table 'session' in field list +SELECT log_warnings = @@session.log_warnings; +ERROR 42S22: Unknown column 'log_warnings' in 'field list' +SET @@global.log_warnings = @start_global_value; +SELECT @@global.log_warnings; +@@global.log_warnings +1 +SET @@session.log_warnings = @start_session_value; +SELECT @@session.log_warnings; +@@session.log_warnings +1 diff --git a/mysql-test/r/max_binlog_cache_size_basic_32.result b/mysql-test/r/max_binlog_cache_size_basic_32.result new file mode 100644 index 00000000000..1dbeb50ff90 --- /dev/null +++ b/mysql-test/r/max_binlog_cache_size_basic_32.result @@ -0,0 +1,145 @@ +SET @start_value = @@global.max_binlog_cache_size; +SELECT @start_value; +@start_value +4294967295 +'#--------------------FN_DYNVARS_072_01------------------------#' +SET @@global.max_binlog_cache_size = 5000; +SET @@global.max_binlog_cache_size = DEFAULT; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294963200 +'#---------------------FN_DYNVARS_072_02-------------------------#' +SET @@global.max_binlog_cache_size = @start_value; +SELECT @@global.max_binlog_cache_size = 4294967295; +@@global.max_binlog_cache_size = 4294967295 +0 +'Bug# 34876: Incorrect Default Value is assigned to variable'; +'#--------------------FN_DYNVARS_072_03------------------------#' +SET @@global.max_binlog_cache_size = 4096; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 4294967295; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294963200 +SET @@global.max_binlog_cache_size = 4294967294; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294963200 +SET @@global.max_binlog_cache_size = 4097; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 65535; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +61440 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_072_04-------------------------#' +SET @@global.max_binlog_cache_size = -1; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '0' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 100000000000; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '100000000000' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294963200 +SET @@global.max_binlog_cache_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'max_binlog_cache_size' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294963200 +SET @@global.max_binlog_cache_size = -1024; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '0' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 1024; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '1024' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 4294967296; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '4294967296' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294963200 +SET @@global.max_binlog_cache_size = 4095; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '4095' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.max_binlog_cache_size = ON; +ERROR 42000: Incorrect argument type to variable 'max_binlog_cache_size' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'max_binlog_cache_size' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +'#-------------------FN_DYNVARS_072_05----------------------------#' +SET @@session.max_binlog_cache_size = 4096; +ERROR HY000: Variable 'max_binlog_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.max_binlog_cache_size; +ERROR HY000: Variable 'max_binlog_cache_size' is a GLOBAL variable +'#----------------------FN_DYNVARS_072_06------------------------#' +SELECT @@global.max_binlog_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_binlog_cache_size'; +@@global.max_binlog_cache_size = VARIABLE_VALUE +1 +SELECT @@max_binlog_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_binlog_cache_size'; +@@max_binlog_cache_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_072_07----------------------#' +SET @@global.max_binlog_cache_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '1' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '0' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +'#---------------------FN_DYNVARS_072_08----------------------#' +SET @@global.max_binlog_cache_size = 5000; +SELECT @@max_binlog_cache_size = @@global.max_binlog_cache_size; +@@max_binlog_cache_size = @@global.max_binlog_cache_size +1 +'#---------------------FN_DYNVARS_072_09----------------------#' +SET max_binlog_cache_size = 6000; +ERROR HY000: Variable 'max_binlog_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@max_binlog_cache_size; +@@max_binlog_cache_size +4096 +SET local.max_binlog_cache_size = 7000; +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 'max_binlog_cache_size = 7000' at line 1 +SELECT local.max_binlog_cache_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.max_binlog_cache_size = 8000; +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 'max_binlog_cache_size = 8000' at line 1 +SELECT global.max_binlog_cache_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT max_binlog_cache_size = @@session.max_binlog_cache_size; +ERROR 42S22: Unknown column 'max_binlog_cache_size' in 'field list' +SET @@global.max_binlog_cache_size = @start_value; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294963200 diff --git a/mysql-test/r/max_binlog_cache_size_basic_64.result b/mysql-test/r/max_binlog_cache_size_basic_64.result new file mode 100644 index 00000000000..30db3f14dd4 --- /dev/null +++ b/mysql-test/r/max_binlog_cache_size_basic_64.result @@ -0,0 +1,141 @@ +SET @start_value = @@global.max_binlog_cache_size; +SELECT @start_value; +@start_value +18446744073709551615 +'#--------------------FN_DYNVARS_072_01------------------------#' +SET @@global.max_binlog_cache_size = 5000; +SET @@global.max_binlog_cache_size = DEFAULT; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +18446744073709547520 +'#---------------------FN_DYNVARS_072_02-------------------------#' +SET @@global.max_binlog_cache_size = @start_value; +SELECT @@global.max_binlog_cache_size = 4294967295; +@@global.max_binlog_cache_size = 4294967295 +0 +'Bug# 34876: Incorrect Default Value is assigned to variable'; +'#--------------------FN_DYNVARS_072_03------------------------#' +SET @@global.max_binlog_cache_size = 4096; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 4294967295; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294963200 +SET @@global.max_binlog_cache_size = 4294967294; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294963200 +SET @@global.max_binlog_cache_size = 4097; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 65535; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +61440 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_072_04-------------------------#' +SET @@global.max_binlog_cache_size = -1; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '0' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 100000000000; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +99999997952 +SET @@global.max_binlog_cache_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'max_binlog_cache_size' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +99999997952 +SET @@global.max_binlog_cache_size = -1024; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '0' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 1024; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '1024' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 4294967296; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4294967296 +SET @@global.max_binlog_cache_size = 4095; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '4095' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.max_binlog_cache_size = ON; +ERROR 42000: Incorrect argument type to variable 'max_binlog_cache_size' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'max_binlog_cache_size' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +'#-------------------FN_DYNVARS_072_05----------------------------#' +SET @@session.max_binlog_cache_size = 4096; +ERROR HY000: Variable 'max_binlog_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.max_binlog_cache_size; +ERROR HY000: Variable 'max_binlog_cache_size' is a GLOBAL variable +'#----------------------FN_DYNVARS_072_06------------------------#' +SELECT @@global.max_binlog_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_binlog_cache_size'; +@@global.max_binlog_cache_size = VARIABLE_VALUE +1 +SELECT @@max_binlog_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_binlog_cache_size'; +@@max_binlog_cache_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_072_07----------------------#' +SET @@global.max_binlog_cache_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '1' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +SET @@global.max_binlog_cache_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_binlog_cache_size value: '0' +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +4096 +'#---------------------FN_DYNVARS_072_08----------------------#' +SET @@global.max_binlog_cache_size = 5000; +SELECT @@max_binlog_cache_size = @@global.max_binlog_cache_size; +@@max_binlog_cache_size = @@global.max_binlog_cache_size +1 +'#---------------------FN_DYNVARS_072_09----------------------#' +SET max_binlog_cache_size = 6000; +ERROR HY000: Variable 'max_binlog_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@max_binlog_cache_size; +@@max_binlog_cache_size +4096 +SET local.max_binlog_cache_size = 7000; +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 'max_binlog_cache_size = 7000' at line 1 +SELECT local.max_binlog_cache_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.max_binlog_cache_size = 8000; +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 'max_binlog_cache_size = 8000' at line 1 +SELECT global.max_binlog_cache_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT max_binlog_cache_size = @@session.max_binlog_cache_size; +ERROR 42S22: Unknown column 'max_binlog_cache_size' in 'field list' +SET @@global.max_binlog_cache_size = @start_value; +SELECT @@global.max_binlog_cache_size; +@@global.max_binlog_cache_size +18446744073709547520 diff --git a/mysql-test/r/max_connect_errors_basic_32.result b/mysql-test/r/max_connect_errors_basic_32.result new file mode 100644 index 00000000000..b786e0ce31a --- /dev/null +++ b/mysql-test/r/max_connect_errors_basic_32.result @@ -0,0 +1,137 @@ +SET @start_value = @@global.max_connect_errors; +SELECT @start_value; +@start_value +10 +'#--------------------FN_DYNVARS_073_01------------------------#' +SET @@global.max_connect_errors = 5000; +SET @@global.max_connect_errors = DEFAULT; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +10 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#---------------------FN_DYNVARS_073_02-------------------------#' +SET @@global.max_connect_errors = @start_value; +SELECT @@global.max_connect_errors = 10; +@@global.max_connect_errors = 10 +1 +'#--------------------FN_DYNVARS_073_03------------------------#' +SET @@global.max_connect_errors = 4096; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4096 +SET @@global.max_connect_errors = 4294967294; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967294 +SET @@global.max_connect_errors = 4294967295; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967295 +SET @@global.max_connect_errors = 1; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = 2; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +2 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_073_04-------------------------#' +SET @@global.max_connect_errors = -1; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '0' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = 100000000000; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '100000000000' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967295 +SET @@global.max_connect_errors = 10000.01; +ERROR 42000: Incorrect argument type to variable 'max_connect_errors' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967295 +SET @@global.max_connect_errors = -1024; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '0' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = 0; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '0' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = 4294967296; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '4294967296' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967295 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.max_connect_errors = ON; +ERROR 42000: Incorrect argument type to variable 'max_connect_errors' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967295 +SET @@global.max_connect_errors = 'test'; +ERROR 42000: Incorrect argument type to variable 'max_connect_errors' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967295 +'#-------------------FN_DYNVARS_073_05----------------------------#' +SET @@session.max_connect_errors = 4096; +ERROR HY000: Variable 'max_connect_errors' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.max_connect_errors; +ERROR HY000: Variable 'max_connect_errors' is a GLOBAL variable +'#----------------------FN_DYNVARS_073_06------------------------#' +SELECT @@global.max_connect_errors = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_connect_errors'; +@@global.max_connect_errors = VARIABLE_VALUE +1 +SELECT @@max_connect_errors = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_connect_errors'; +@@max_connect_errors = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_073_07----------------------#' +SET @@global.max_connect_errors = TRUE; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '0' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +'#---------------------FN_DYNVARS_073_08----------------------#' +SET @@global.max_connect_errors = 5000; +SELECT @@max_connect_errors = @@global.max_connect_errors; +@@max_connect_errors = @@global.max_connect_errors +1 +'#---------------------FN_DYNVARS_073_09----------------------#' +SET max_connect_errors = 6000; +ERROR HY000: Variable 'max_connect_errors' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@max_connect_errors; +@@max_connect_errors +5000 +SET local.max_connect_errors = 7000; +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 'max_connect_errors = 7000' at line 1 +SELECT local.max_connect_errors; +ERROR 42S02: Unknown table 'local' in field list +SET global.max_connect_errors = 8000; +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 'max_connect_errors = 8000' at line 1 +SELECT global.max_connect_errors; +ERROR 42S02: Unknown table 'global' in field list +SELECT max_connect_errors = @@session.max_connect_errors; +ERROR 42S22: Unknown column 'max_connect_errors' in 'field list' +SET @@global.max_connect_errors = @start_value; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +10 diff --git a/mysql-test/r/max_connect_errors_basic_64.result b/mysql-test/r/max_connect_errors_basic_64.result new file mode 100644 index 00000000000..8117b650651 --- /dev/null +++ b/mysql-test/r/max_connect_errors_basic_64.result @@ -0,0 +1,133 @@ +SET @start_value = @@global.max_connect_errors; +SELECT @start_value; +@start_value +10 +'#--------------------FN_DYNVARS_073_01------------------------#' +SET @@global.max_connect_errors = 5000; +SET @@global.max_connect_errors = DEFAULT; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +10 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#---------------------FN_DYNVARS_073_02-------------------------#' +SET @@global.max_connect_errors = @start_value; +SELECT @@global.max_connect_errors = 10; +@@global.max_connect_errors = 10 +1 +'#--------------------FN_DYNVARS_073_03------------------------#' +SET @@global.max_connect_errors = 4096; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4096 +SET @@global.max_connect_errors = 4294967294; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967294 +SET @@global.max_connect_errors = 4294967295; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967295 +SET @@global.max_connect_errors = 1; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = 2; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +2 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_073_04-------------------------#' +SET @@global.max_connect_errors = -1; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '0' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = 100000000000; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +100000000000 +SET @@global.max_connect_errors = 10000.01; +ERROR 42000: Incorrect argument type to variable 'max_connect_errors' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +100000000000 +SET @@global.max_connect_errors = -1024; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '0' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = 0; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '0' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = 4294967296; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967296 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.max_connect_errors = ON; +ERROR 42000: Incorrect argument type to variable 'max_connect_errors' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967296 +SET @@global.max_connect_errors = 'test'; +ERROR 42000: Incorrect argument type to variable 'max_connect_errors' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +4294967296 +'#-------------------FN_DYNVARS_073_05----------------------------#' +SET @@session.max_connect_errors = 4096; +ERROR HY000: Variable 'max_connect_errors' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@session.max_connect_errors; +ERROR HY000: Variable 'max_connect_errors' is a GLOBAL variable +'#----------------------FN_DYNVARS_073_06------------------------#' +SELECT @@global.max_connect_errors = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_connect_errors'; +@@global.max_connect_errors = VARIABLE_VALUE +1 +SELECT @@max_connect_errors = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_connect_errors'; +@@max_connect_errors = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_073_07----------------------#' +SET @@global.max_connect_errors = TRUE; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +SET @@global.max_connect_errors = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_connect_errors value: '0' +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +1 +'#---------------------FN_DYNVARS_073_08----------------------#' +SET @@global.max_connect_errors = 5000; +SELECT @@max_connect_errors = @@global.max_connect_errors; +@@max_connect_errors = @@global.max_connect_errors +1 +'#---------------------FN_DYNVARS_073_09----------------------#' +SET max_connect_errors = 6000; +ERROR HY000: Variable 'max_connect_errors' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@max_connect_errors; +@@max_connect_errors +5000 +SET local.max_connect_errors = 7000; +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 'max_connect_errors = 7000' at line 1 +SELECT local.max_connect_errors; +ERROR 42S02: Unknown table 'local' in field list +SET global.max_connect_errors = 8000; +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 'max_connect_errors = 8000' at line 1 +SELECT global.max_connect_errors; +ERROR 42S02: Unknown table 'global' in field list +SELECT max_connect_errors = @@session.max_connect_errors; +ERROR 42S22: Unknown column 'max_connect_errors' in 'field list' +SET @@global.max_connect_errors = @start_value; +SELECT @@global.max_connect_errors; +@@global.max_connect_errors +10 diff --git a/mysql-test/r/max_heap_table_size_basic_32.result b/mysql-test/r/max_heap_table_size_basic_32.result new file mode 100644 index 00000000000..04eaa3ddd19 --- /dev/null +++ b/mysql-test/r/max_heap_table_size_basic_32.result @@ -0,0 +1,196 @@ +SET @start_global_value = @@global.max_heap_table_size; +SELECT @start_global_value; +@start_global_value +1048576 +SET @start_session_value = @@session.max_heap_table_size; +SELECT @start_session_value; +@start_session_value +1048576 +'#--------------------FN_DYNVARS_077_01-------------------------#' +SET @@global.max_heap_table_size = 1677721610; +SET @@global.max_heap_table_size = DEFAULT; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16777216 +SET @@session.max_heap_table_size = 1677721610; +SET @@session.max_heap_table_size = DEFAULT; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16777216 +'#--------------------FN_DYNVARS_077_02-------------------------#' +SET @@global.max_heap_table_size = DEFAULT; +SELECT @@global.max_heap_table_size = 16777216; +@@global.max_heap_table_size = 16777216 +1 +SET @@session.max_heap_table_size = DEFAULT; +SELECT @@session.max_heap_table_size = 16777216; +@@session.max_heap_table_size = 16777216 +1 +'#--------------------FN_DYNVARS_077_03-------------------------#' +SET @@global.max_heap_table_size = 16384; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 16385; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 65535; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +64512 +SET @@global.max_heap_table_size = 4294967294; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294966272 +SET @@global.max_heap_table_size = 4294967295; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294966272 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_077_04-------------------------#' +SET @@session.max_heap_table_size = 16384; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16384 +SET @@session.max_heap_table_size = 16385; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16384 +SET @@session.max_heap_table_size = 65535; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +64512 +SET @@session.max_heap_table_size = 4294967294; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +4294966272 +SET @@session.max_heap_table_size = 4294967295; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +4294966272 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#------------------FN_DYNVARS_077_05-----------------------#' +SET @@global.max_heap_table_size = -1; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '0' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = -1024; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '0' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 1024; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '1024' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 16383; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '16383' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 4294967296; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294966272 +SET @@global.max_heap_table_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 +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294966272 +SET @@global.max_heap_table_size = test; +ERROR 42000: Incorrect argument type to variable 'max_heap_table_size' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294966272 +SET @@session.max_heap_table_size = -1; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '0' +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16384 +SET @@session.max_heap_table_size = 16383; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '16383' +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16384 +SET @@session.max_heap_table_size = 4294967296; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +4294966272 +SET @@session.max_heap_table_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.max_heap_table_size = 10737418241; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +4294966272 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.max_heap_table_size = test; +ERROR 42000: Incorrect argument type to variable 'max_heap_table_size' +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +4294966272 +'#------------------FN_DYNVARS_077_06-----------------------#' +SELECT @@global.max_heap_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_heap_table_size'; +@@global.max_heap_table_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_077_07-----------------------#' +SELECT @@session.max_heap_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_heap_table_size'; +@@session.max_heap_table_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_077_08-----------------------#' +SET @@global.max_heap_table_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '1' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '0' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +'#---------------------FN_DYNVARS_077_09----------------------#' +SET @@global.max_heap_table_size = 163845; +SELECT @@max_heap_table_size = @@global.max_heap_table_size; +@@max_heap_table_size = @@global.max_heap_table_size +0 +'#---------------------FN_DYNVARS_077_10----------------------#' +SET @@max_heap_table_size = 16777216; +SELECT @@max_heap_table_size = @@local.max_heap_table_size; +@@max_heap_table_size = @@local.max_heap_table_size +1 +SELECT @@local.max_heap_table_size = @@session.max_heap_table_size; +@@local.max_heap_table_size = @@session.max_heap_table_size +1 +'#---------------------FN_DYNVARS_077_11----------------------#' +SET max_heap_table_size = 316777216; +SELECT @@max_heap_table_size; +@@max_heap_table_size +316776448 +SELECT local.max_heap_table_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.max_heap_table_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT max_heap_table_size = @@session.max_heap_table_size; +ERROR 42S22: Unknown column 'max_heap_table_size' in 'field list' +SET @@global.max_heap_table_size = @start_global_value; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +1048576 +SET @@session.max_heap_table_size = @start_session_value; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +1048576 diff --git a/mysql-test/r/max_heap_table_size_basic_64.result b/mysql-test/r/max_heap_table_size_basic_64.result new file mode 100644 index 00000000000..ebab80f376b --- /dev/null +++ b/mysql-test/r/max_heap_table_size_basic_64.result @@ -0,0 +1,196 @@ +SET @start_global_value = @@global.max_heap_table_size; +SELECT @start_global_value; +@start_global_value +1048576 +SET @start_session_value = @@session.max_heap_table_size; +SELECT @start_session_value; +@start_session_value +1048576 +'#--------------------FN_DYNVARS_077_01-------------------------#' +SET @@global.max_heap_table_size = 1677721610; +SET @@global.max_heap_table_size = DEFAULT; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16777216 +SET @@session.max_heap_table_size = 1677721610; +SET @@session.max_heap_table_size = DEFAULT; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16777216 +'#--------------------FN_DYNVARS_077_02-------------------------#' +SET @@global.max_heap_table_size = DEFAULT; +SELECT @@global.max_heap_table_size = 16777216; +@@global.max_heap_table_size = 16777216 +1 +SET @@session.max_heap_table_size = DEFAULT; +SELECT @@session.max_heap_table_size = 16777216; +@@session.max_heap_table_size = 16777216 +1 +'#--------------------FN_DYNVARS_077_03-------------------------#' +SET @@global.max_heap_table_size = 16384; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 16385; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 65535; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +64512 +SET @@global.max_heap_table_size = 4294967294; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294966272 +SET @@global.max_heap_table_size = 4294967295; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294966272 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_077_04-------------------------#' +SET @@session.max_heap_table_size = 16384; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16384 +SET @@session.max_heap_table_size = 16385; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16384 +SET @@session.max_heap_table_size = 65535; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +64512 +SET @@session.max_heap_table_size = 4294967294; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +4294966272 +SET @@session.max_heap_table_size = 4294967295; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +4294966272 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#------------------FN_DYNVARS_077_05-----------------------#' +SET @@global.max_heap_table_size = -1; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '0' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = -1024; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '0' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 1024; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '1024' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 16383; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '16383' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = 4294967296; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294967296 +SET @@global.max_heap_table_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 +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294967296 +SET @@global.max_heap_table_size = test; +ERROR 42000: Incorrect argument type to variable 'max_heap_table_size' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +4294967296 +SET @@session.max_heap_table_size = -1; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '0' +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16384 +SET @@session.max_heap_table_size = 16383; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '16383' +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +16384 +SET @@session.max_heap_table_size = 4294967296; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +4294967296 +SET @@session.max_heap_table_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.max_heap_table_size = 10737418241; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +10737418240 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.max_heap_table_size = test; +ERROR 42000: Incorrect argument type to variable 'max_heap_table_size' +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +10737418240 +'#------------------FN_DYNVARS_077_06-----------------------#' +SELECT @@global.max_heap_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_heap_table_size'; +@@global.max_heap_table_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_077_07-----------------------#' +SELECT @@session.max_heap_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_heap_table_size'; +@@session.max_heap_table_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_077_08-----------------------#' +SET @@global.max_heap_table_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '1' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +SET @@global.max_heap_table_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_heap_table_size value: '0' +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +16384 +'#---------------------FN_DYNVARS_077_09----------------------#' +SET @@global.max_heap_table_size = 163845; +SELECT @@max_heap_table_size = @@global.max_heap_table_size; +@@max_heap_table_size = @@global.max_heap_table_size +0 +'#---------------------FN_DYNVARS_077_10----------------------#' +SET @@max_heap_table_size = 16777216; +SELECT @@max_heap_table_size = @@local.max_heap_table_size; +@@max_heap_table_size = @@local.max_heap_table_size +1 +SELECT @@local.max_heap_table_size = @@session.max_heap_table_size; +@@local.max_heap_table_size = @@session.max_heap_table_size +1 +'#---------------------FN_DYNVARS_077_11----------------------#' +SET max_heap_table_size = 316777216; +SELECT @@max_heap_table_size; +@@max_heap_table_size +316776448 +SELECT local.max_heap_table_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.max_heap_table_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT max_heap_table_size = @@session.max_heap_table_size; +ERROR 42S22: Unknown column 'max_heap_table_size' in 'field list' +SET @@global.max_heap_table_size = @start_global_value; +SELECT @@global.max_heap_table_size; +@@global.max_heap_table_size +1048576 +SET @@session.max_heap_table_size = @start_session_value; +SELECT @@session.max_heap_table_size; +@@session.max_heap_table_size +1048576 diff --git a/mysql-test/r/max_seeks_for_key_basic_32.result b/mysql-test/r/max_seeks_for_key_basic_32.result new file mode 100644 index 00000000000..64828fbe619 --- /dev/null +++ b/mysql-test/r/max_seeks_for_key_basic_32.result @@ -0,0 +1,180 @@ +SET @start_global_value = @@global.max_seeks_for_key; +SELECT @start_global_value; +@start_global_value +4294967295 +SET @start_session_value = @@session.max_seeks_for_key; +SELECT @start_session_value; +@start_session_value +4294967295 +'#--------------------FN_DYNVARS_083_01-------------------------#' +SET @@global.max_seeks_for_key = 100; +SET @@global.max_seeks_for_key = DEFAULT; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967295 +SET @@session.max_seeks_for_key = 200; +SET @@session.max_seeks_for_key = DEFAULT; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967295 +'#--------------------FN_DYNVARS_083_02-------------------------#' +SET @@global.max_seeks_for_key = DEFAULT; +SELECT @@global.max_seeks_for_key = 4294967295; +@@global.max_seeks_for_key = 4294967295 +1 +SET @@session.max_seeks_for_key = DEFAULT; +SELECT @@session.max_seeks_for_key = 4294967295; +@@session.max_seeks_for_key = 4294967295 +1 +'#--------------------FN_DYNVARS_083_03-------------------------#' +SET @@global.max_seeks_for_key = 1; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +SET @@global.max_seeks_for_key = 2; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +2 +SET @@global.max_seeks_for_key = 65536; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +65536 +SET @@global.max_seeks_for_key = 4294967295; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967295 +SET @@global.max_seeks_for_key = 4294967294; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967294 +'#--------------------FN_DYNVARS_083_04-------------------------#' +SET @@session.max_seeks_for_key = 1; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +1 +SET @@session.max_seeks_for_key = 2; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +2 +SET @@session.max_seeks_for_key = 4294967295; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967295 +SET @@session.max_seeks_for_key = 4294967294; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967294 +SET @@session.max_seeks_for_key = 65535; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +65535 +'#------------------FN_DYNVARS_083_05-----------------------#' +SET @@global.max_seeks_for_key = 0; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +SET @@global.max_seeks_for_key = -1024; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +SET @@global.max_seeks_for_key = 4294967296; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '4294967296' +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967295 +SET @@global.max_seeks_for_key = 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 +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967295 +SET @@global.max_seeks_for_key = test; +ERROR 42000: Incorrect argument type to variable 'max_seeks_for_key' +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967295 +SET @@session.max_seeks_for_key = 0; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +1 +SET @@session.max_seeks_for_key = -2; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +1 +SET @@session.max_seeks_for_key = 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.max_seeks_for_key = 4294967296; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '4294967296' +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967295 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.max_seeks_for_key = test; +ERROR 42000: Incorrect argument type to variable 'max_seeks_for_key' +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967295 +'#------------------FN_DYNVARS_083_06-----------------------#' +SELECT @@global.max_seeks_for_key = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_seeks_for_key'; +@@global.max_seeks_for_key = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_083_07-----------------------#' +SELECT @@session.max_seeks_for_key = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_seeks_for_key'; +@@session.max_seeks_for_key = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_083_08-----------------------#' +SET @@global.max_seeks_for_key = TRUE; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +SET @@global.max_seeks_for_key = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +'#---------------------FN_DYNVARS_083_09----------------------#' +SET @@global.max_seeks_for_key = 10; +SELECT @@max_seeks_for_key = @@global.max_seeks_for_key; +@@max_seeks_for_key = @@global.max_seeks_for_key +0 +'#---------------------FN_DYNVARS_083_10----------------------#' +SET @@max_seeks_for_key = 100; +SELECT @@max_seeks_for_key = @@local.max_seeks_for_key; +@@max_seeks_for_key = @@local.max_seeks_for_key +1 +SELECT @@local.max_seeks_for_key = @@session.max_seeks_for_key; +@@local.max_seeks_for_key = @@session.max_seeks_for_key +1 +'#---------------------FN_DYNVARS_083_11----------------------#' +SET max_seeks_for_key = 1; +SELECT @@max_seeks_for_key; +@@max_seeks_for_key +1 +SELECT local.max_seeks_for_key; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.max_seeks_for_key; +ERROR 42S02: Unknown table 'session' in field list +SELECT max_seeks_for_key = @@session.max_seeks_for_key; +ERROR 42S22: Unknown column 'max_seeks_for_key' in 'field list' +SET @@global.max_seeks_for_key = @start_global_value; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967295 +SET @@session.max_seeks_for_key = @start_session_value; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967295 diff --git a/mysql-test/r/max_seeks_for_key_basic_64.result b/mysql-test/r/max_seeks_for_key_basic_64.result new file mode 100644 index 00000000000..eefb829cdae --- /dev/null +++ b/mysql-test/r/max_seeks_for_key_basic_64.result @@ -0,0 +1,176 @@ +SET @start_global_value = @@global.max_seeks_for_key; +SELECT @start_global_value; +@start_global_value +18446744073709551615 +SET @start_session_value = @@session.max_seeks_for_key; +SELECT @start_session_value; +@start_session_value +18446744073709551615 +'#--------------------FN_DYNVARS_083_01-------------------------#' +SET @@global.max_seeks_for_key = 100; +SET @@global.max_seeks_for_key = DEFAULT; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +18446744073709551615 +SET @@session.max_seeks_for_key = 200; +SET @@session.max_seeks_for_key = DEFAULT; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +18446744073709551615 +'#--------------------FN_DYNVARS_083_02-------------------------#' +SET @@global.max_seeks_for_key = DEFAULT; +SELECT @@global.max_seeks_for_key = 4294967295; +@@global.max_seeks_for_key = 4294967295 +0 +SET @@session.max_seeks_for_key = DEFAULT; +SELECT @@session.max_seeks_for_key = 4294967295; +@@session.max_seeks_for_key = 4294967295 +0 +'#--------------------FN_DYNVARS_083_03-------------------------#' +SET @@global.max_seeks_for_key = 1; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +SET @@global.max_seeks_for_key = 2; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +2 +SET @@global.max_seeks_for_key = 65536; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +65536 +SET @@global.max_seeks_for_key = 4294967295; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967295 +SET @@global.max_seeks_for_key = 4294967294; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967294 +'#--------------------FN_DYNVARS_083_04-------------------------#' +SET @@session.max_seeks_for_key = 1; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +1 +SET @@session.max_seeks_for_key = 2; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +2 +SET @@session.max_seeks_for_key = 4294967295; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967295 +SET @@session.max_seeks_for_key = 4294967294; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967294 +SET @@session.max_seeks_for_key = 65535; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +65535 +'#------------------FN_DYNVARS_083_05-----------------------#' +SET @@global.max_seeks_for_key = 0; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +SET @@global.max_seeks_for_key = -1024; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +SET @@global.max_seeks_for_key = 4294967296; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967296 +SET @@global.max_seeks_for_key = 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 +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967296 +SET @@global.max_seeks_for_key = test; +ERROR 42000: Incorrect argument type to variable 'max_seeks_for_key' +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +4294967296 +SET @@session.max_seeks_for_key = 0; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +1 +SET @@session.max_seeks_for_key = -2; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +1 +SET @@session.max_seeks_for_key = 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.max_seeks_for_key = 4294967296; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967296 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.max_seeks_for_key = test; +ERROR 42000: Incorrect argument type to variable 'max_seeks_for_key' +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +4294967296 +'#------------------FN_DYNVARS_083_06-----------------------#' +SELECT @@global.max_seeks_for_key = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_seeks_for_key'; +@@global.max_seeks_for_key = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_083_07-----------------------#' +SELECT @@session.max_seeks_for_key = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_seeks_for_key'; +@@session.max_seeks_for_key = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_083_08-----------------------#' +SET @@global.max_seeks_for_key = TRUE; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +SET @@global.max_seeks_for_key = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_seeks_for_key value: '0' +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +1 +'#---------------------FN_DYNVARS_083_09----------------------#' +SET @@global.max_seeks_for_key = 10; +SELECT @@max_seeks_for_key = @@global.max_seeks_for_key; +@@max_seeks_for_key = @@global.max_seeks_for_key +0 +'#---------------------FN_DYNVARS_083_10----------------------#' +SET @@max_seeks_for_key = 100; +SELECT @@max_seeks_for_key = @@local.max_seeks_for_key; +@@max_seeks_for_key = @@local.max_seeks_for_key +1 +SELECT @@local.max_seeks_for_key = @@session.max_seeks_for_key; +@@local.max_seeks_for_key = @@session.max_seeks_for_key +1 +'#---------------------FN_DYNVARS_083_11----------------------#' +SET max_seeks_for_key = 1; +SELECT @@max_seeks_for_key; +@@max_seeks_for_key +1 +SELECT local.max_seeks_for_key; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.max_seeks_for_key; +ERROR 42S02: Unknown table 'session' in field list +SELECT max_seeks_for_key = @@session.max_seeks_for_key; +ERROR 42S22: Unknown column 'max_seeks_for_key' in 'field list' +SET @@global.max_seeks_for_key = @start_global_value; +SELECT @@global.max_seeks_for_key; +@@global.max_seeks_for_key +18446744073709551615 +SET @@session.max_seeks_for_key = @start_session_value; +SELECT @@session.max_seeks_for_key; +@@session.max_seeks_for_key +18446744073709551615 diff --git a/mysql-test/r/max_tmp_tables_basic_32.result b/mysql-test/r/max_tmp_tables_basic_32.result new file mode 100644 index 00000000000..5f959069661 --- /dev/null +++ b/mysql-test/r/max_tmp_tables_basic_32.result @@ -0,0 +1,197 @@ +SET @start_global_value = @@global.max_tmp_tables; +SELECT @start_global_value; +@start_global_value +32 +SET @start_session_value = @@session.max_tmp_tables; +SELECT @start_session_value; +@start_session_value +32 +'#--------------------FN_DYNVARS_086_01-------------------------#' +SET @@global.max_tmp_tables = 1000; +SET @@global.max_tmp_tables = DEFAULT; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +32 +SET @@session.max_tmp_tables = 1000; +SET @@session.max_tmp_tables = DEFAULT; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +32 +'#--------------------FN_DYNVARS_086_02-------------------------#' +SET @@global.max_tmp_tables = DEFAULT; +SELECT @@global.max_tmp_tables = 32; +@@global.max_tmp_tables = 32 +1 +SET @@session.max_tmp_tables = DEFAULT; +SELECT @@session.max_tmp_tables = 32; +@@session.max_tmp_tables = 32 +1 +'#--------------------FN_DYNVARS_086_03-------------------------#' +SET @@global.max_tmp_tables = 1; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +SET @@global.max_tmp_tables = 2; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +2 +SET @@global.max_tmp_tables = 65536; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +65536 +SET @@global.max_tmp_tables = 4294967295; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +4294967295 +SET @@global.max_tmp_tables = 4294967294; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +4294967294 +'#--------------------FN_DYNVARS_086_04-------------------------#' +SET @@session.max_tmp_tables = 1; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +1 +SET @@session.max_tmp_tables = 2; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +2 +SET @@session.max_tmp_tables = 65536; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +65536 +SET @@session.max_tmp_tables = 4294967295; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +4294967295 +SET @@session.max_tmp_tables = 4294967294; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +4294967294 +'#------------------FN_DYNVARS_086_05-----------------------#' +SET @@global.max_tmp_tables = -1024; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +SET @@global.max_tmp_tables = 4294967296; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '4294967296' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +4294967295 +SET @@global.max_tmp_tables = -1; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +SET @@global.max_tmp_tables = 429496729500; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '429496729500' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +4294967295 +SET @@global.max_tmp_tables = 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 +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +4294967295 +SET @@global.max_tmp_tables = test; +ERROR 42000: Incorrect argument type to variable 'max_tmp_tables' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +4294967295 +SET @@session.max_tmp_tables = 4294967296; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '4294967296' +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +4294967295 +SET @@session.max_tmp_tables = -1; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +1 +SET @@session.max_tmp_tables = 429496729500; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '429496729500' +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +4294967295 +SET @@session.max_tmp_tables = -001; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +1 +SET @@session.max_tmp_tables = 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.max_tmp_tables = 10737418241; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '10737418241' +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +4294967295 +SET @@session.max_tmp_tables = test; +ERROR 42000: Incorrect argument type to variable 'max_tmp_tables' +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +4294967295 +'#------------------FN_DYNVARS_086_06-----------------------#' +SELECT @@global.max_tmp_tables = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_tmp_tables'; +@@global.max_tmp_tables = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_086_07-----------------------#' +SELECT @@session.max_tmp_tables = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_tmp_tables'; +@@session.max_tmp_tables = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_086_08-----------------------#' +SET @@global.max_tmp_tables = TRUE; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +SET @@global.max_tmp_tables = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +'#---------------------FN_DYNVARS_086_09----------------------#' +SET @@global.max_tmp_tables = 20; +SELECT @@max_tmp_tables = @@global.max_tmp_tables; +@@max_tmp_tables = @@global.max_tmp_tables +0 +'#---------------------FN_DYNVARS_086_10----------------------#' +SET @@max_tmp_tables = 255; +SELECT @@max_tmp_tables = @@local.max_tmp_tables; +@@max_tmp_tables = @@local.max_tmp_tables +1 +SELECT @@local.max_tmp_tables = @@session.max_tmp_tables; +@@local.max_tmp_tables = @@session.max_tmp_tables +1 +'#---------------------FN_DYNVARS_086_11----------------------#' +SET max_tmp_tables = 102; +SELECT @@max_tmp_tables; +@@max_tmp_tables +102 +SELECT local.max_tmp_tables; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.max_tmp_tables; +ERROR 42S02: Unknown table 'session' in field list +SELECT max_tmp_tables = @@session.max_tmp_tables; +ERROR 42S22: Unknown column 'max_tmp_tables' in 'field list' +SET @@global.max_tmp_tables = @start_global_value; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +32 +SET @@session.max_tmp_tables = @start_session_value; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +32 diff --git a/mysql-test/r/max_tmp_tables_basic_64.result b/mysql-test/r/max_tmp_tables_basic_64.result new file mode 100644 index 00000000000..4b9f68c509e --- /dev/null +++ b/mysql-test/r/max_tmp_tables_basic_64.result @@ -0,0 +1,187 @@ +SET @start_global_value = @@global.max_tmp_tables; +SELECT @start_global_value; +@start_global_value +32 +SET @start_session_value = @@session.max_tmp_tables; +SELECT @start_session_value; +@start_session_value +32 +'#--------------------FN_DYNVARS_086_01-------------------------#' +SET @@global.max_tmp_tables = 1000; +SET @@global.max_tmp_tables = DEFAULT; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +32 +SET @@session.max_tmp_tables = 1000; +SET @@session.max_tmp_tables = DEFAULT; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +32 +'#--------------------FN_DYNVARS_086_02-------------------------#' +SET @@global.max_tmp_tables = DEFAULT; +SELECT @@global.max_tmp_tables = 32; +@@global.max_tmp_tables = 32 +1 +SET @@session.max_tmp_tables = DEFAULT; +SELECT @@session.max_tmp_tables = 32; +@@session.max_tmp_tables = 32 +1 +'#--------------------FN_DYNVARS_086_03-------------------------#' +SET @@global.max_tmp_tables = 1; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +SET @@global.max_tmp_tables = 2; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +2 +SET @@global.max_tmp_tables = 65536; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +65536 +SET @@global.max_tmp_tables = 4294967295; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +4294967295 +SET @@global.max_tmp_tables = 4294967294; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +4294967294 +'#--------------------FN_DYNVARS_086_04-------------------------#' +SET @@session.max_tmp_tables = 1; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +1 +SET @@session.max_tmp_tables = 2; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +2 +SET @@session.max_tmp_tables = 65536; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +65536 +SET @@session.max_tmp_tables = 4294967295; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +4294967295 +SET @@session.max_tmp_tables = 4294967294; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +4294967294 +'#------------------FN_DYNVARS_086_05-----------------------#' +SET @@global.max_tmp_tables = -1024; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +SET @@global.max_tmp_tables = 4294967296; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +4294967296 +SET @@global.max_tmp_tables = -1; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +SET @@global.max_tmp_tables = 429496729500; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +429496729500 +SET @@global.max_tmp_tables = 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 +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +429496729500 +SET @@global.max_tmp_tables = test; +ERROR 42000: Incorrect argument type to variable 'max_tmp_tables' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +429496729500 +SET @@session.max_tmp_tables = 4294967296; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +4294967296 +SET @@session.max_tmp_tables = -1; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +1 +SET @@session.max_tmp_tables = 429496729500; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +429496729500 +SET @@session.max_tmp_tables = -001; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +1 +SET @@session.max_tmp_tables = 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.max_tmp_tables = 10737418241; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +10737418241 +SET @@session.max_tmp_tables = test; +ERROR 42000: Incorrect argument type to variable 'max_tmp_tables' +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +10737418241 +'#------------------FN_DYNVARS_086_06-----------------------#' +SELECT @@global.max_tmp_tables = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_tmp_tables'; +@@global.max_tmp_tables = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_086_07-----------------------#' +SELECT @@session.max_tmp_tables = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='max_tmp_tables'; +@@session.max_tmp_tables = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_086_08-----------------------#' +SET @@global.max_tmp_tables = TRUE; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +SET @@global.max_tmp_tables = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_tmp_tables value: '0' +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +1 +'#---------------------FN_DYNVARS_086_09----------------------#' +SET @@global.max_tmp_tables = 20; +SELECT @@max_tmp_tables = @@global.max_tmp_tables; +@@max_tmp_tables = @@global.max_tmp_tables +0 +'#---------------------FN_DYNVARS_086_10----------------------#' +SET @@max_tmp_tables = 255; +SELECT @@max_tmp_tables = @@local.max_tmp_tables; +@@max_tmp_tables = @@local.max_tmp_tables +1 +SELECT @@local.max_tmp_tables = @@session.max_tmp_tables; +@@local.max_tmp_tables = @@session.max_tmp_tables +1 +'#---------------------FN_DYNVARS_086_11----------------------#' +SET max_tmp_tables = 102; +SELECT @@max_tmp_tables; +@@max_tmp_tables +102 +SELECT local.max_tmp_tables; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.max_tmp_tables; +ERROR 42S02: Unknown table 'session' in field list +SELECT max_tmp_tables = @@session.max_tmp_tables; +ERROR 42S22: Unknown column 'max_tmp_tables' in 'field list' +SET @@global.max_tmp_tables = @start_global_value; +SELECT @@global.max_tmp_tables; +@@global.max_tmp_tables +32 +SET @@session.max_tmp_tables = @start_session_value; +SELECT @@session.max_tmp_tables; +@@session.max_tmp_tables +32 diff --git a/mysql-test/r/max_write_lock_count_basic_32.result b/mysql-test/r/max_write_lock_count_basic_32.result new file mode 100644 index 00000000000..0c9c3c00c1f --- /dev/null +++ b/mysql-test/r/max_write_lock_count_basic_32.result @@ -0,0 +1,108 @@ +SET @start_global_value = @@global.max_write_lock_count; +SELECT @start_global_value; +@start_global_value +4294967295 +'#--------------------FN_DYNVARS_088_01-------------------------#' +SET @@global.max_write_lock_count = 1000; +SET @@global.max_write_lock_count = DEFAULT; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967295 +'#--------------------FN_DYNVARS_088_02-------------------------#' +SET @@global.max_write_lock_count = DEFAULT; +SELECT @@global.max_write_lock_count = 4294967295; +@@global.max_write_lock_count = 4294967295 +1 +'#--------------------FN_DYNVARS_088_03-------------------------#' +SET @@global.max_write_lock_count = 1; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +SET @@global.max_write_lock_count = 2; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +2 +SET @@global.max_write_lock_count = 65536; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +65536 +SET @@global.max_write_lock_count = 4294967295; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967295 +SET @@global.max_write_lock_count = 4294967294; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967294 +'#------------------FN_DYNVARS_088_04-----------------------#' +SET @@global.max_write_lock_count = -1024; +Warnings: +Warning 1292 Truncated incorrect max_write_lock_count value: '0' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +SET @@global.max_write_lock_count = 4294967296; +Warnings: +Warning 1292 Truncated incorrect max_write_lock_count value: '4294967296' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967295 +SET @@global.max_write_lock_count = -1; +Warnings: +Warning 1292 Truncated incorrect max_write_lock_count value: '0' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +SET @@global.max_write_lock_count = 429496729500; +Warnings: +Warning 1292 Truncated incorrect max_write_lock_count value: '429496729500' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967295 +SET @@global.max_write_lock_count = 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 +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967295 +SET @@global.max_write_lock_count = test; +ERROR 42000: Incorrect argument type to variable 'max_write_lock_count' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967295 +'#------------------FN_DYNVARS_088_05-----------------------#' +SELECT @@global.max_write_lock_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_write_lock_count'; +@@global.max_write_lock_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_088_06-----------------------#' +SET @@global.max_write_lock_count = TRUE; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +SET @@global.max_write_lock_count = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_write_lock_count value: '0' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +'#---------------------FN_DYNVARS_088_07----------------------#' +SET @@global.max_write_lock_count = 20; +SELECT @@max_write_lock_count = @@global.max_write_lock_count; +@@max_write_lock_count = @@global.max_write_lock_count +1 +'#---------------------FN_DYNVARS_088_08----------------------#' +SET @@global.max_write_lock_count = 102; +SELECT @@max_write_lock_count; +@@max_write_lock_count +102 +SELECT local.max_write_lock_count; +ERROR 42S02: Unknown table 'local' in field list +SELECT global.max_write_lock_count; +ERROR 42S02: Unknown table 'global' in field list +SELECT max_write_lock_count = @@global.max_write_lock_count; +ERROR 42S22: Unknown column 'max_write_lock_count' in 'field list' +SET @@global.max_write_lock_count = @start_global_value; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967295 diff --git a/mysql-test/r/max_write_lock_count_basic_64.result b/mysql-test/r/max_write_lock_count_basic_64.result new file mode 100644 index 00000000000..d74586841dd --- /dev/null +++ b/mysql-test/r/max_write_lock_count_basic_64.result @@ -0,0 +1,104 @@ +SET @start_global_value = @@global.max_write_lock_count; +SELECT @start_global_value; +@start_global_value +18446744073709551615 +'#--------------------FN_DYNVARS_088_01-------------------------#' +SET @@global.max_write_lock_count = 1000; +SET @@global.max_write_lock_count = DEFAULT; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +18446744073709551615 +'#--------------------FN_DYNVARS_088_02-------------------------#' +SET @@global.max_write_lock_count = DEFAULT; +SELECT @@global.max_write_lock_count = 4294967295; +@@global.max_write_lock_count = 4294967295 +0 +'#--------------------FN_DYNVARS_088_03-------------------------#' +SET @@global.max_write_lock_count = 1; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +SET @@global.max_write_lock_count = 2; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +2 +SET @@global.max_write_lock_count = 65536; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +65536 +SET @@global.max_write_lock_count = 4294967295; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967295 +SET @@global.max_write_lock_count = 4294967294; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967294 +'#------------------FN_DYNVARS_088_04-----------------------#' +SET @@global.max_write_lock_count = -1024; +Warnings: +Warning 1292 Truncated incorrect max_write_lock_count value: '0' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +SET @@global.max_write_lock_count = 4294967296; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +4294967296 +SET @@global.max_write_lock_count = -1; +Warnings: +Warning 1292 Truncated incorrect max_write_lock_count value: '0' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +SET @@global.max_write_lock_count = 429496729500; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +429496729500 +SET @@global.max_write_lock_count = 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 +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +429496729500 +SET @@global.max_write_lock_count = test; +ERROR 42000: Incorrect argument type to variable 'max_write_lock_count' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +429496729500 +'#------------------FN_DYNVARS_088_05-----------------------#' +SELECT @@global.max_write_lock_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='max_write_lock_count'; +@@global.max_write_lock_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_088_06-----------------------#' +SET @@global.max_write_lock_count = TRUE; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +SET @@global.max_write_lock_count = FALSE; +Warnings: +Warning 1292 Truncated incorrect max_write_lock_count value: '0' +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +1 +'#---------------------FN_DYNVARS_088_07----------------------#' +SET @@global.max_write_lock_count = 20; +SELECT @@max_write_lock_count = @@global.max_write_lock_count; +@@max_write_lock_count = @@global.max_write_lock_count +1 +'#---------------------FN_DYNVARS_088_08----------------------#' +SET @@global.max_write_lock_count = 102; +SELECT @@max_write_lock_count; +@@max_write_lock_count +102 +SELECT local.max_write_lock_count; +ERROR 42S02: Unknown table 'local' in field list +SELECT global.max_write_lock_count; +ERROR 42S02: Unknown table 'global' in field list +SELECT max_write_lock_count = @@global.max_write_lock_count; +ERROR 42S22: Unknown column 'max_write_lock_count' in 'field list' +SET @@global.max_write_lock_count = @start_global_value; +SELECT @@global.max_write_lock_count; +@@global.max_write_lock_count +18446744073709551615 diff --git a/mysql-test/r/min_examined_row_limit_basic_32.result b/mysql-test/r/min_examined_row_limit_basic_32.result new file mode 100644 index 00000000000..c0315944a8a --- /dev/null +++ b/mysql-test/r/min_examined_row_limit_basic_32.result @@ -0,0 +1,180 @@ +SET @start_global_value = @@global.min_examined_row_limit; +SELECT @start_global_value; +@start_global_value +0 +SET @start_session_value = @@session.min_examined_row_limit; +SELECT @start_session_value; +@start_session_value +0 +'#--------------------FN_DYNVARS_089_01-------------------------#' +SET @@global.min_examined_row_limit = 100; +SET @@global.min_examined_row_limit = DEFAULT; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +SET @@session.min_examined_row_limit = 200; +SET @@session.min_examined_row_limit = DEFAULT; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +0 +'#--------------------FN_DYNVARS_089_02-------------------------#' +SET @@global.min_examined_row_limit = DEFAULT; +SELECT @@global.min_examined_row_limit = 0; +@@global.min_examined_row_limit = 0 +1 +SET @@session.min_examined_row_limit = DEFAULT; +SELECT @@session.min_examined_row_limit = 0; +@@session.min_examined_row_limit = 0 +1 +'#--------------------FN_DYNVARS_089_03-------------------------#' +SET @@global.min_examined_row_limit = 0; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +SET @@global.min_examined_row_limit = 1; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +1 +SET @@global.min_examined_row_limit = 60020; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +60020 +SET @@global.min_examined_row_limit = 65535; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +65535 +SET @@global.min_examined_row_limit = 4294967295; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +4294967295 +SET @@global.min_examined_row_limit = 4294967294; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +4294967294 +'#--------------------FN_DYNVARS_089_04-------------------------#' +SET @@session.min_examined_row_limit = 0; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +0 +SET @@session.min_examined_row_limit = 1; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +1 +SET @@session.min_examined_row_limit = 50050; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +50050 +SET @@session.min_examined_row_limit = 65535; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +65535 +SET @@session.min_examined_row_limit = 4294967295; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967295 +SET @@session.min_examined_row_limit = 4294967294; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967294 +'#------------------FN_DYNVARS_089_05-----------------------#' +SET @@global.min_examined_row_limit = 429496726; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +429496726 +SET @@global.min_examined_row_limit = -1024; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +SET @@global.min_examined_row_limit = 429496729500; +Warnings: +Warning 1292 Truncated incorrect min_examined_row_limit value: '429496729500' +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +4294967295 +SET @@global.min_examined_row_limit = 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 +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +4294967295 +SET @@global.min_examined_row_limit = test; +ERROR 42000: Incorrect argument type to variable 'min_examined_row_limit' +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +4294967295 +SET @@session.min_examined_row_limit = 4294967296; +Warnings: +Warning 1292 Truncated incorrect min_examined_row_limit value: '4294967296' +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967295 +SET @@session.min_examined_row_limit = -1; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +0 +SET @@session.min_examined_row_limit = 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.min_examined_row_limit = 4294967295021; +Warnings: +Warning 1292 Truncated incorrect min_examined_row_limit value: '4294967295021' +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967295 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.min_examined_row_limit = test; +ERROR 42000: Incorrect argument type to variable 'min_examined_row_limit' +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967295 +'#------------------FN_DYNVARS_089_06-----------------------#' +SELECT @@global.min_examined_row_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='min_examined_row_limit'; +@@global.min_examined_row_limit = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_089_07-----------------------#' +SELECT @@session.min_examined_row_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='min_examined_row_limit'; +@@session.min_examined_row_limit = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_089_08-----------------------#' +SET @@global.min_examined_row_limit = TRUE; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +1 +SET @@global.min_examined_row_limit = FALSE; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +'#---------------------FN_DYNVARS_089_09----------------------#' +SET @@global.min_examined_row_limit = 10; +SELECT @@min_examined_row_limit = @@global.min_examined_row_limit; +@@min_examined_row_limit = @@global.min_examined_row_limit +0 +'#---------------------FN_DYNVARS_089_10----------------------#' +SET @@min_examined_row_limit = 100; +SELECT @@min_examined_row_limit = @@local.min_examined_row_limit; +@@min_examined_row_limit = @@local.min_examined_row_limit +1 +SELECT @@local.min_examined_row_limit = @@session.min_examined_row_limit; +@@local.min_examined_row_limit = @@session.min_examined_row_limit +1 +'#---------------------FN_DYNVARS_089_11----------------------#' +SET min_examined_row_limit = 1; +SELECT @@min_examined_row_limit; +@@min_examined_row_limit +1 +SELECT local.min_examined_row_limit; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.min_examined_row_limit; +ERROR 42S02: Unknown table 'session' in field list +SELECT min_examined_row_limit = @@session.min_examined_row_limit; +ERROR 42S22: Unknown column 'min_examined_row_limit' in 'field list' +SET @@global.min_examined_row_limit = @start_global_value; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +SET @@session.min_examined_row_limit = @start_session_value; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +0 diff --git a/mysql-test/r/min_examined_row_limit_basic_64.result b/mysql-test/r/min_examined_row_limit_basic_64.result new file mode 100644 index 00000000000..fa11659c6c5 --- /dev/null +++ b/mysql-test/r/min_examined_row_limit_basic_64.result @@ -0,0 +1,174 @@ +SET @start_global_value = @@global.min_examined_row_limit; +SELECT @start_global_value; +@start_global_value +0 +SET @start_session_value = @@session.min_examined_row_limit; +SELECT @start_session_value; +@start_session_value +0 +'#--------------------FN_DYNVARS_089_01-------------------------#' +SET @@global.min_examined_row_limit = 100; +SET @@global.min_examined_row_limit = DEFAULT; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +SET @@session.min_examined_row_limit = 200; +SET @@session.min_examined_row_limit = DEFAULT; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +0 +'#--------------------FN_DYNVARS_089_02-------------------------#' +SET @@global.min_examined_row_limit = DEFAULT; +SELECT @@global.min_examined_row_limit = 0; +@@global.min_examined_row_limit = 0 +1 +SET @@session.min_examined_row_limit = DEFAULT; +SELECT @@session.min_examined_row_limit = 0; +@@session.min_examined_row_limit = 0 +1 +'#--------------------FN_DYNVARS_089_03-------------------------#' +SET @@global.min_examined_row_limit = 0; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +SET @@global.min_examined_row_limit = 1; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +1 +SET @@global.min_examined_row_limit = 60020; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +60020 +SET @@global.min_examined_row_limit = 65535; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +65535 +SET @@global.min_examined_row_limit = 4294967295; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +4294967295 +SET @@global.min_examined_row_limit = 4294967294; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +4294967294 +'#--------------------FN_DYNVARS_089_04-------------------------#' +SET @@session.min_examined_row_limit = 0; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +0 +SET @@session.min_examined_row_limit = 1; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +1 +SET @@session.min_examined_row_limit = 50050; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +50050 +SET @@session.min_examined_row_limit = 65535; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +65535 +SET @@session.min_examined_row_limit = 4294967295; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967295 +SET @@session.min_examined_row_limit = 4294967294; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967294 +'#------------------FN_DYNVARS_089_05-----------------------#' +SET @@global.min_examined_row_limit = 429496726; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +429496726 +SET @@global.min_examined_row_limit = -1024; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +SET @@global.min_examined_row_limit = 429496729500; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +429496729500 +SET @@global.min_examined_row_limit = 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 +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +429496729500 +SET @@global.min_examined_row_limit = test; +ERROR 42000: Incorrect argument type to variable 'min_examined_row_limit' +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +429496729500 +SET @@session.min_examined_row_limit = 4294967296; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967296 +SET @@session.min_examined_row_limit = -1; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +0 +SET @@session.min_examined_row_limit = 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.min_examined_row_limit = 4294967295021; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967295021 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.min_examined_row_limit = test; +ERROR 42000: Incorrect argument type to variable 'min_examined_row_limit' +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +4294967295021 +'#------------------FN_DYNVARS_089_06-----------------------#' +SELECT @@global.min_examined_row_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='min_examined_row_limit'; +@@global.min_examined_row_limit = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_089_07-----------------------#' +SELECT @@session.min_examined_row_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='min_examined_row_limit'; +@@session.min_examined_row_limit = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_089_08-----------------------#' +SET @@global.min_examined_row_limit = TRUE; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +1 +SET @@global.min_examined_row_limit = FALSE; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +'#---------------------FN_DYNVARS_089_09----------------------#' +SET @@global.min_examined_row_limit = 10; +SELECT @@min_examined_row_limit = @@global.min_examined_row_limit; +@@min_examined_row_limit = @@global.min_examined_row_limit +0 +'#---------------------FN_DYNVARS_089_10----------------------#' +SET @@min_examined_row_limit = 100; +SELECT @@min_examined_row_limit = @@local.min_examined_row_limit; +@@min_examined_row_limit = @@local.min_examined_row_limit +1 +SELECT @@local.min_examined_row_limit = @@session.min_examined_row_limit; +@@local.min_examined_row_limit = @@session.min_examined_row_limit +1 +'#---------------------FN_DYNVARS_089_11----------------------#' +SET min_examined_row_limit = 1; +SELECT @@min_examined_row_limit; +@@min_examined_row_limit +1 +SELECT local.min_examined_row_limit; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.min_examined_row_limit; +ERROR 42S02: Unknown table 'session' in field list +SELECT min_examined_row_limit = @@session.min_examined_row_limit; +ERROR 42S22: Unknown column 'min_examined_row_limit' in 'field list' +SET @@global.min_examined_row_limit = @start_global_value; +SELECT @@global.min_examined_row_limit; +@@global.min_examined_row_limit +0 +SET @@session.min_examined_row_limit = @start_session_value; +SELECT @@session.min_examined_row_limit; +@@session.min_examined_row_limit +0 diff --git a/mysql-test/r/multi_range_count_basic_32.result b/mysql-test/r/multi_range_count_basic_32.result new file mode 100644 index 00000000000..f6ac6490479 --- /dev/null +++ b/mysql-test/r/multi_range_count_basic_32.result @@ -0,0 +1,192 @@ +SET @start_global_value = @@global.multi_range_count; +SELECT @start_global_value; +@start_global_value +256 +SET @start_session_value = @@session.multi_range_count; +SELECT @start_session_value; +@start_session_value +256 +'#--------------------FN_DYNVARS_090_01-------------------------#' +SET @@global.multi_range_count = 100; +SET @@global.multi_range_count = DEFAULT; +SELECT @@global.multi_range_count; +@@global.multi_range_count +256 +SET @@session.multi_range_count = 200; +SET @@session.multi_range_count = DEFAULT; +SELECT @@session.multi_range_count; +@@session.multi_range_count +256 +'#--------------------FN_DYNVARS_090_02-------------------------#' +SET @@global.multi_range_count = DEFAULT; +SELECT @@global.multi_range_count = 256; +@@global.multi_range_count = 256 +1 +SET @@session.multi_range_count = DEFAULT; +SELECT @@session.multi_range_count = 256; +@@session.multi_range_count = 256 +1 +'#--------------------FN_DYNVARS_090_03-------------------------#' +SET @@global.multi_range_count = 1; +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +SET @@global.multi_range_count = 60020; +SELECT @@global.multi_range_count; +@@global.multi_range_count +60020 +SET @@global.multi_range_count = 65535; +SELECT @@global.multi_range_count; +@@global.multi_range_count +65535 +SET @@global.multi_range_count = 4294967295; +SELECT @@global.multi_range_count; +@@global.multi_range_count +4294967295 +SET @@global.multi_range_count = 4294967294; +SELECT @@global.multi_range_count; +@@global.multi_range_count +4294967294 +'#--------------------FN_DYNVARS_090_04-------------------------#' +SET @@session.multi_range_count = 1; +SELECT @@session.multi_range_count; +@@session.multi_range_count +1 +SET @@session.multi_range_count = 50050; +SELECT @@session.multi_range_count; +@@session.multi_range_count +50050 +SET @@session.multi_range_count = 65535; +SELECT @@session.multi_range_count; +@@session.multi_range_count +65535 +SET @@session.multi_range_count = 4294967295; +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967295 +SET @@session.multi_range_count = 4294967294; +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967294 +'#------------------FN_DYNVARS_090_05-----------------------#' +SET @@global.multi_range_count = 0; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +SET @@global.multi_range_count = 4294967296; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '4294967296' +SELECT @@global.multi_range_count; +@@global.multi_range_count +4294967295 +SET @@global.multi_range_count = -1024; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +SET @@global.multi_range_count = 429496729500; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '429496729500' +SELECT @@global.multi_range_count; +@@global.multi_range_count +4294967295 +SET @@global.multi_range_count = 65530.34; +ERROR 42000: Incorrect argument type to variable 'multi_range_count' +SELECT @@global.multi_range_count; +@@global.multi_range_count +4294967295 +SET @@global.multi_range_count = test; +ERROR 42000: Incorrect argument type to variable 'multi_range_count' +SELECT @@global.multi_range_count; +@@global.multi_range_count +4294967295 +SET @@session.multi_range_count = 0; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@session.multi_range_count; +@@session.multi_range_count +1 +SET @@session.multi_range_count = 4294967296; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '4294967296' +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967295 +SET @@session.multi_range_count = -1; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@session.multi_range_count; +@@session.multi_range_count +1 +SET @@session.multi_range_count = 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.multi_range_count = 4294967295021; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '4294967295021' +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967295 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.multi_range_count = test; +ERROR 42000: Incorrect argument type to variable 'multi_range_count' +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967295 +'#------------------FN_DYNVARS_090_06-----------------------#' +SELECT @@global.multi_range_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='multi_range_count'; +@@global.multi_range_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_090_07-----------------------#' +SELECT @@session.multi_range_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='multi_range_count'; +@@session.multi_range_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_090_08-----------------------#' +SET @@global.multi_range_count = TRUE; +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +SET @@global.multi_range_count = FALSE; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +'#---------------------FN_DYNVARS_090_09----------------------#' +SET @@global.multi_range_count = 10; +SELECT @@multi_range_count = @@global.multi_range_count; +@@multi_range_count = @@global.multi_range_count +0 +'#---------------------FN_DYNVARS_090_10----------------------#' +SET @@multi_range_count = 100; +SELECT @@multi_range_count = @@local.multi_range_count; +@@multi_range_count = @@local.multi_range_count +1 +SELECT @@local.multi_range_count = @@session.multi_range_count; +@@local.multi_range_count = @@session.multi_range_count +1 +'#---------------------FN_DYNVARS_090_11----------------------#' +SET multi_range_count = 1; +SELECT @@multi_range_count; +@@multi_range_count +1 +SELECT local.multi_range_count; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.multi_range_count; +ERROR 42S02: Unknown table 'session' in field list +SELECT multi_range_count = @@session.multi_range_count; +ERROR 42S22: Unknown column 'multi_range_count' in 'field list' +SET @@global.multi_range_count = @start_global_value; +SELECT @@global.multi_range_count; +@@global.multi_range_count +256 +SET @@session.multi_range_count = @start_session_value; +SELECT @@session.multi_range_count; +@@session.multi_range_count +256 diff --git a/mysql-test/r/multi_range_count_basic_64.result b/mysql-test/r/multi_range_count_basic_64.result new file mode 100644 index 00000000000..f2115aec2e2 --- /dev/null +++ b/mysql-test/r/multi_range_count_basic_64.result @@ -0,0 +1,184 @@ +SET @start_global_value = @@global.multi_range_count; +SELECT @start_global_value; +@start_global_value +256 +SET @start_session_value = @@session.multi_range_count; +SELECT @start_session_value; +@start_session_value +256 +'#--------------------FN_DYNVARS_090_01-------------------------#' +SET @@global.multi_range_count = 100; +SET @@global.multi_range_count = DEFAULT; +SELECT @@global.multi_range_count; +@@global.multi_range_count +256 +SET @@session.multi_range_count = 200; +SET @@session.multi_range_count = DEFAULT; +SELECT @@session.multi_range_count; +@@session.multi_range_count +256 +'#--------------------FN_DYNVARS_090_02-------------------------#' +SET @@global.multi_range_count = DEFAULT; +SELECT @@global.multi_range_count = 256; +@@global.multi_range_count = 256 +1 +SET @@session.multi_range_count = DEFAULT; +SELECT @@session.multi_range_count = 256; +@@session.multi_range_count = 256 +1 +'#--------------------FN_DYNVARS_090_03-------------------------#' +SET @@global.multi_range_count = 1; +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +SET @@global.multi_range_count = 60020; +SELECT @@global.multi_range_count; +@@global.multi_range_count +60020 +SET @@global.multi_range_count = 65535; +SELECT @@global.multi_range_count; +@@global.multi_range_count +65535 +SET @@global.multi_range_count = 4294967295; +SELECT @@global.multi_range_count; +@@global.multi_range_count +4294967295 +SET @@global.multi_range_count = 4294967294; +SELECT @@global.multi_range_count; +@@global.multi_range_count +4294967294 +'#--------------------FN_DYNVARS_090_04-------------------------#' +SET @@session.multi_range_count = 1; +SELECT @@session.multi_range_count; +@@session.multi_range_count +1 +SET @@session.multi_range_count = 50050; +SELECT @@session.multi_range_count; +@@session.multi_range_count +50050 +SET @@session.multi_range_count = 65535; +SELECT @@session.multi_range_count; +@@session.multi_range_count +65535 +SET @@session.multi_range_count = 4294967295; +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967295 +SET @@session.multi_range_count = 4294967294; +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967294 +'#------------------FN_DYNVARS_090_05-----------------------#' +SET @@global.multi_range_count = 0; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +SET @@global.multi_range_count = 4294967296; +SELECT @@global.multi_range_count; +@@global.multi_range_count +4294967296 +SET @@global.multi_range_count = -1024; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +SET @@global.multi_range_count = 429496729500; +SELECT @@global.multi_range_count; +@@global.multi_range_count +429496729500 +SET @@global.multi_range_count = 65530.34; +ERROR 42000: Incorrect argument type to variable 'multi_range_count' +SELECT @@global.multi_range_count; +@@global.multi_range_count +429496729500 +SET @@global.multi_range_count = test; +ERROR 42000: Incorrect argument type to variable 'multi_range_count' +SELECT @@global.multi_range_count; +@@global.multi_range_count +429496729500 +SET @@session.multi_range_count = 0; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@session.multi_range_count; +@@session.multi_range_count +1 +SET @@session.multi_range_count = 4294967296; +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967296 +SET @@session.multi_range_count = -1; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@session.multi_range_count; +@@session.multi_range_count +1 +SET @@session.multi_range_count = 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.multi_range_count = 4294967295021; +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967295021 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.multi_range_count = test; +ERROR 42000: Incorrect argument type to variable 'multi_range_count' +SELECT @@session.multi_range_count; +@@session.multi_range_count +4294967295021 +'#------------------FN_DYNVARS_090_06-----------------------#' +SELECT @@global.multi_range_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='multi_range_count'; +@@global.multi_range_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_090_07-----------------------#' +SELECT @@session.multi_range_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='multi_range_count'; +@@session.multi_range_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_090_08-----------------------#' +SET @@global.multi_range_count = TRUE; +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +SET @@global.multi_range_count = FALSE; +Warnings: +Warning 1292 Truncated incorrect multi_range_count value: '0' +SELECT @@global.multi_range_count; +@@global.multi_range_count +1 +'#---------------------FN_DYNVARS_090_09----------------------#' +SET @@global.multi_range_count = 10; +SELECT @@multi_range_count = @@global.multi_range_count; +@@multi_range_count = @@global.multi_range_count +0 +'#---------------------FN_DYNVARS_090_10----------------------#' +SET @@multi_range_count = 100; +SELECT @@multi_range_count = @@local.multi_range_count; +@@multi_range_count = @@local.multi_range_count +1 +SELECT @@local.multi_range_count = @@session.multi_range_count; +@@local.multi_range_count = @@session.multi_range_count +1 +'#---------------------FN_DYNVARS_090_11----------------------#' +SET multi_range_count = 1; +SELECT @@multi_range_count; +@@multi_range_count +1 +SELECT local.multi_range_count; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.multi_range_count; +ERROR 42S02: Unknown table 'session' in field list +SELECT multi_range_count = @@session.multi_range_count; +ERROR 42S22: Unknown column 'multi_range_count' in 'field list' +SET @@global.multi_range_count = @start_global_value; +SELECT @@global.multi_range_count; +@@global.multi_range_count +256 +SET @@session.multi_range_count = @start_session_value; +SELECT @@session.multi_range_count; +@@session.multi_range_count +256 diff --git a/mysql-test/r/myisam_max_sort_file_size_basic_32.result b/mysql-test/r/myisam_max_sort_file_size_basic_32.result new file mode 100644 index 00000000000..64d1168685c --- /dev/null +++ b/mysql-test/r/myisam_max_sort_file_size_basic_32.result @@ -0,0 +1,114 @@ +SET @start_global_value = @@global.myisam_max_sort_file_size; +SELECT @start_global_value; +@start_global_value +2147483647 +'#--------------------FN_DYNVARS_094_01-------------------------#' +SET @@global.myisam_max_sort_file_size = 500000; +SET @@global.myisam_max_sort_file_size = DEFAULT; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +2146435072 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_094_02-------------------------#' +SET @@global.myisam_max_sort_file_size = DEFAULT; +SELECT @@global.myisam_max_sort_file_size = 2147483648; +@@global.myisam_max_sort_file_size = 2147483648 +0 +'#--------------------FN_DYNVARS_094_03-------------------------#' +SET @@global.myisam_max_sort_file_size = 0; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = 1024; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = 123456789; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +122683392 +SET @@global.myisam_max_sort_file_size = 2147483648*2; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +4294967296 +SET @@global.myisam_max_sort_file_size = 2147483648*1024; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +2199023255552 +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +2199023255552 +SET @@global.myisam_max_sort_file_size = 2147483648*2147483648; +'#--------------------FN_DYNVARS_094_04-------------------------#' +SET @@myisam_max_sort_file_size = 2; +ERROR HY000: Variable 'myisam_max_sort_file_size' is a GLOBAL variable and should be set with SET GLOBAL +SET @@session.myisam_max_sort_file_size = 3; +ERROR HY000: Variable 'myisam_max_sort_file_size' is a GLOBAL variable and should be set with SET GLOBAL +SET @@local.myisam_max_sort_file_size = 4; +ERROR HY000: Variable 'myisam_max_sort_file_size' is a GLOBAL variable and should be set with SET GLOBAL +'#------------------FN_DYNVARS_094_05-----------------------#' +SET @@global.myisam_max_sort_file_size = -1; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = -2147483648; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = -2147483649; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_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 +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = 2147483649.56; +ERROR 42000: Incorrect argument type to variable 'myisam_max_sort_file_size' +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = 1G; +ERROR 42000: Incorrect argument type to variable 'myisam_max_sort_file_size' +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +'#------------------FN_DYNVARS_094_06-----------------------#' +SET @@global.myisam_max_sort_file_size = 3000; +SELECT @@global.myisam_max_sort_file_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='myisam_max_sort_file_size'; +@@global.myisam_max_sort_file_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_094_07-----------------------#' +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='myisam_max_sort_file_size'; +count(VARIABLE_VALUE) +1 +'#------------------FN_DYNVARS_094_08-----------------------#' +SET @@global.myisam_max_sort_file_size = TRUE; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = FALSE; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.myisam_max_sort_file_size = 512; +SELECT @@myisam_max_sort_file_size = @@global.myisam_max_sort_file_size; +@@myisam_max_sort_file_size = @@global.myisam_max_sort_file_size +1 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET myisam_max_sort_file_size = 2048; +ERROR HY000: Variable 'myisam_max_sort_file_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT myisam_max_sort_file_size; +ERROR 42S22: Unknown column 'myisam_max_sort_file_size' in 'field list' +SELECT @@myisam_max_sort_file_size; +@@myisam_max_sort_file_size +0 +SET global myisam_max_sort_file_size = 64; +SET @@global.myisam_max_sort_file_size = @start_global_value; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +2146435072 diff --git a/mysql-test/r/myisam_max_sort_file_size_basic_64.result b/mysql-test/r/myisam_max_sort_file_size_basic_64.result new file mode 100644 index 00000000000..00ff1dfc1ab --- /dev/null +++ b/mysql-test/r/myisam_max_sort_file_size_basic_64.result @@ -0,0 +1,114 @@ +SET @start_global_value = @@global.myisam_max_sort_file_size; +SELECT @start_global_value; +@start_global_value +9223372036854775807 +'#--------------------FN_DYNVARS_094_01-------------------------#' +SET @@global.myisam_max_sort_file_size = 500000; +SET @@global.myisam_max_sort_file_size = DEFAULT; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +9223372036853727232 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_094_02-------------------------#' +SET @@global.myisam_max_sort_file_size = DEFAULT; +SELECT @@global.myisam_max_sort_file_size = 2147483648; +@@global.myisam_max_sort_file_size = 2147483648 +0 +'#--------------------FN_DYNVARS_094_03-------------------------#' +SET @@global.myisam_max_sort_file_size = 0; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = 1024; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = 123456789; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +122683392 +SET @@global.myisam_max_sort_file_size = 2147483648*2; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +4294967296 +SET @@global.myisam_max_sort_file_size = 2147483648*1024; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +2199023255552 +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +2199023255552 +SET @@global.myisam_max_sort_file_size = 2147483648*2147483648; +'#--------------------FN_DYNVARS_094_04-------------------------#' +SET @@myisam_max_sort_file_size = 2; +ERROR HY000: Variable 'myisam_max_sort_file_size' is a GLOBAL variable and should be set with SET GLOBAL +SET @@session.myisam_max_sort_file_size = 3; +ERROR HY000: Variable 'myisam_max_sort_file_size' is a GLOBAL variable and should be set with SET GLOBAL +SET @@local.myisam_max_sort_file_size = 4; +ERROR HY000: Variable 'myisam_max_sort_file_size' is a GLOBAL variable and should be set with SET GLOBAL +'#------------------FN_DYNVARS_094_05-----------------------#' +SET @@global.myisam_max_sort_file_size = -1; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = -2147483648; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = -2147483649; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_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 +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = 2147483649.56; +ERROR 42000: Incorrect argument type to variable 'myisam_max_sort_file_size' +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = 1G; +ERROR 42000: Incorrect argument type to variable 'myisam_max_sort_file_size' +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +'#------------------FN_DYNVARS_094_06-----------------------#' +SET @@global.myisam_max_sort_file_size = 3000; +SELECT @@global.myisam_max_sort_file_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='myisam_max_sort_file_size'; +@@global.myisam_max_sort_file_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_094_07-----------------------#' +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='myisam_max_sort_file_size'; +count(VARIABLE_VALUE) +1 +'#------------------FN_DYNVARS_094_08-----------------------#' +SET @@global.myisam_max_sort_file_size = TRUE; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +SET @@global.myisam_max_sort_file_size = FALSE; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +0 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.myisam_max_sort_file_size = 512; +SELECT @@myisam_max_sort_file_size = @@global.myisam_max_sort_file_size; +@@myisam_max_sort_file_size = @@global.myisam_max_sort_file_size +1 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET myisam_max_sort_file_size = 2048; +ERROR HY000: Variable 'myisam_max_sort_file_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT myisam_max_sort_file_size; +ERROR 42S22: Unknown column 'myisam_max_sort_file_size' in 'field list' +SELECT @@myisam_max_sort_file_size; +@@myisam_max_sort_file_size +0 +SET global myisam_max_sort_file_size = 64; +SET @@global.myisam_max_sort_file_size = @start_global_value; +SELECT @@global.myisam_max_sort_file_size; +@@global.myisam_max_sort_file_size +9223372036853727232 diff --git a/mysql-test/r/myisam_repair_threads_basic_32.result b/mysql-test/r/myisam_repair_threads_basic_32.result new file mode 100644 index 00000000000..c91128e3f4c --- /dev/null +++ b/mysql-test/r/myisam_repair_threads_basic_32.result @@ -0,0 +1,180 @@ +SET @start_global_value = @@global.myisam_repair_threads; +SELECT @start_global_value; +@start_global_value +1 +SET @start_session_value = @@session.myisam_repair_threads; +SELECT @start_session_value; +@start_session_value +1 +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.myisam_repair_threads = 100; +SET @@global.myisam_repair_threads = DEFAULT; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = 200; +SET @@session.myisam_repair_threads = DEFAULT; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.myisam_repair_threads = DEFAULT; +SELECT @@global.myisam_repair_threads = 1; +@@global.myisam_repair_threads = 1 +1 +SET @@session.myisam_repair_threads = DEFAULT; +SELECT @@session.myisam_repair_threads = 1; +@@session.myisam_repair_threads = 1 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.myisam_repair_threads = 1; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@global.myisam_repair_threads = 4294967295; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +4294967295 +SET @@global.myisam_repair_threads = 655354; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +655354 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.myisam_repair_threads = 1; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = 4294967295; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +4294967295 +SET @@session.myisam_repair_threads = 655345; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +655345 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.myisam_repair_threads = 0; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@global.myisam_repair_threads = -1024; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@global.myisam_repair_threads = 429496729533; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '429496729533' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +4294967295 +SET @@global.myisam_repair_threads = 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 +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +4294967295 +SET @@global.myisam_repair_threads = test; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +4294967295 +SET @@global.myisam_repair_threads = "test"; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +4294967295 +SET @@global.myisam_repair_threads = 'test'; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +4294967295 +SET @@global.myisam_repair_threads = ON; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +4294967295 +SET @@session.myisam_repair_threads = 0; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = -2; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = 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 +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = test; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = "test"; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.myisam_repair_threads = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='myisam_repair_threads '; +@@global.myisam_repair_threads = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.myisam_repair_threads = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='myisam_repair_threads '; +@@session.myisam_repair_threads = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_08-----------------------#' +SET @@global.myisam_repair_threads = TRUE; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@global.myisam_repair_threads = FALSE; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.myisam_repair_threads = 10; +SELECT @@myisam_repair_threads = @@global.myisam_repair_threads ; +@@myisam_repair_threads = @@global.myisam_repair_threads +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@myisam_repair_threads = 100; +SELECT @@myisam_repair_threads = @@local.myisam_repair_threads ; +@@myisam_repair_threads = @@local.myisam_repair_threads +1 +SELECT @@local.myisam_repair_threads = @@session.myisam_repair_threads ; +@@local.myisam_repair_threads = @@session.myisam_repair_threads +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET myisam_repair_threads = 1; +SELECT @@myisam_repair_threads ; +@@myisam_repair_threads +1 +SELECT local.myisam_repair_threads ; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.myisam_repair_threads ; +ERROR 42S02: Unknown table 'session' in field list +SELECT myisam_repair_threads = @@session.myisam_repair_threads ; +ERROR 42S22: Unknown column 'myisam_repair_threads' in 'field list' +SET @@global.myisam_repair_threads = @start_global_value; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = @start_session_value; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 diff --git a/mysql-test/r/myisam_repair_threads_basic_64.result b/mysql-test/r/myisam_repair_threads_basic_64.result new file mode 100644 index 00000000000..8271451cc9e --- /dev/null +++ b/mysql-test/r/myisam_repair_threads_basic_64.result @@ -0,0 +1,178 @@ +SET @start_global_value = @@global.myisam_repair_threads; +SELECT @start_global_value; +@start_global_value +1 +SET @start_session_value = @@session.myisam_repair_threads; +SELECT @start_session_value; +@start_session_value +1 +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.myisam_repair_threads = 100; +SET @@global.myisam_repair_threads = DEFAULT; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = 200; +SET @@session.myisam_repair_threads = DEFAULT; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.myisam_repair_threads = DEFAULT; +SELECT @@global.myisam_repair_threads = 1; +@@global.myisam_repair_threads = 1 +1 +SET @@session.myisam_repair_threads = DEFAULT; +SELECT @@session.myisam_repair_threads = 1; +@@session.myisam_repair_threads = 1 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.myisam_repair_threads = 1; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@global.myisam_repair_threads = 4294967295; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +4294967295 +SET @@global.myisam_repair_threads = 655354; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +655354 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.myisam_repair_threads = 1; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = 4294967295; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +4294967295 +SET @@session.myisam_repair_threads = 655345; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +655345 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.myisam_repair_threads = 0; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@global.myisam_repair_threads = -1024; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@global.myisam_repair_threads = 429496729533; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +429496729533 +SET @@global.myisam_repair_threads = 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 +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +429496729533 +SET @@global.myisam_repair_threads = test; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +429496729533 +SET @@global.myisam_repair_threads = "test"; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +429496729533 +SET @@global.myisam_repair_threads = 'test'; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +429496729533 +SET @@global.myisam_repair_threads = ON; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +429496729533 +SET @@session.myisam_repair_threads = 0; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = -2; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = 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 +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = test; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = "test"; +ERROR 42000: Incorrect argument type to variable 'myisam_repair_threads' +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.myisam_repair_threads = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='myisam_repair_threads '; +@@global.myisam_repair_threads = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.myisam_repair_threads = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='myisam_repair_threads '; +@@session.myisam_repair_threads = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_08-----------------------#' +SET @@global.myisam_repair_threads = TRUE; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@global.myisam_repair_threads = FALSE; +Warnings: +Warning 1292 Truncated incorrect myisam_repair_threads value: '0' +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.myisam_repair_threads = 10; +SELECT @@myisam_repair_threads = @@global.myisam_repair_threads ; +@@myisam_repair_threads = @@global.myisam_repair_threads +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@myisam_repair_threads = 100; +SELECT @@myisam_repair_threads = @@local.myisam_repair_threads ; +@@myisam_repair_threads = @@local.myisam_repair_threads +1 +SELECT @@local.myisam_repair_threads = @@session.myisam_repair_threads ; +@@local.myisam_repair_threads = @@session.myisam_repair_threads +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET myisam_repair_threads = 1; +SELECT @@myisam_repair_threads ; +@@myisam_repair_threads +1 +SELECT local.myisam_repair_threads ; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.myisam_repair_threads ; +ERROR 42S02: Unknown table 'session' in field list +SELECT myisam_repair_threads = @@session.myisam_repair_threads ; +ERROR 42S22: Unknown column 'myisam_repair_threads' in 'field list' +SET @@global.myisam_repair_threads = @start_global_value; +SELECT @@global.myisam_repair_threads ; +@@global.myisam_repair_threads +1 +SET @@session.myisam_repair_threads = @start_session_value; +SELECT @@session.myisam_repair_threads ; +@@session.myisam_repair_threads +1 diff --git a/mysql-test/r/myisam_sort_buffer_size_basic_32.result b/mysql-test/r/myisam_sort_buffer_size_basic_32.result new file mode 100644 index 00000000000..74d2fb3ec86 --- /dev/null +++ b/mysql-test/r/myisam_sort_buffer_size_basic_32.result @@ -0,0 +1,184 @@ +SET @start_global_value = @@global.myisam_sort_buffer_size ; +SELECT @start_global_value; +@start_global_value +8388608 +SET @start_session_value = @@session.myisam_sort_buffer_size ; +SELECT @start_session_value; +@start_session_value +8388608 +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.myisam_sort_buffer_size = 100; +SET @@global.myisam_sort_buffer_size = DEFAULT; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +8388608 +SET @@session.myisam_sort_buffer_size = 200; +SET @@session.myisam_sort_buffer_size = DEFAULT; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +8388608 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.myisam_sort_buffer_size = DEFAULT; +SELECT @@global.myisam_sort_buffer_size = 8388608; +@@global.myisam_sort_buffer_size = 8388608 +1 +SET @@session.myisam_sort_buffer_size = DEFAULT; +SELECT @@session.myisam_sort_buffer_size = 8388608; +@@session.myisam_sort_buffer_size = 8388608 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.myisam_sort_buffer_size = 4; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +SET @@global.myisam_sort_buffer_size = 4294967295; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4294967295 +SET @@global.myisam_sort_buffer_size = 655354; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +655354 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.myisam_sort_buffer_size = 4; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_sort_buffer_size = 4294967295; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4294967295 +SET @@session.myisam_sort_buffer_size = 655345; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +655345 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.myisam_sort_buffer_size = 0; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +SET @@global.myisam_sort_buffer_size = -1024; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +SET @@global.myisam_sort_buffer_size = 429496729533; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '429496729533' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4294967295 +SET @@global.myisam_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 +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4294967295 +SET @@global.myisam_sort_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4294967295 +SET @@global.myisam_sort_buffer_size = "test"; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4294967295 +SET @@global.myisam_sort_buffer_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4294967295 +SET @@global.myisam_sort_buffer_size = ON; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4294967295 +SET @@session.myisam_sort_buffer_size = 0; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_sort_buffer_size = -2; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_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 +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_sort_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_sort_buffer_size = "test"; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.myisam_sort_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='myisam_sort_buffer_size '; +@@global.myisam_sort_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.myisam_sort_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='myisam_sort_buffer_size '; +@@session.myisam_sort_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_08-----------------------#' +SET @@global.myisam_sort_buffer_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '1' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +SET @@global.myisam_sort_buffer_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.myisam_sort_buffer_size = 10; +SELECT @@myisam_sort_buffer_size = @@global.myisam_sort_buffer_size ; +@@myisam_sort_buffer_size = @@global.myisam_sort_buffer_size +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@myisam_sort_buffer_size = 100; +SELECT @@myisam_sort_buffer_size = @@local.myisam_sort_buffer_size ; +@@myisam_sort_buffer_size = @@local.myisam_sort_buffer_size +1 +SELECT @@local.myisam_sort_buffer_size = @@session.myisam_sort_buffer_size ; +@@local.myisam_sort_buffer_size = @@session.myisam_sort_buffer_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET myisam_sort_buffer_size = 1; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '1' +SELECT @@myisam_sort_buffer_size ; +@@myisam_sort_buffer_size +4 +SELECT local.myisam_sort_buffer_size ; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.myisam_sort_buffer_size ; +ERROR 42S02: Unknown table 'session' in field list +SELECT myisam_sort_buffer_size = @@session.myisam_sort_buffer_size ; +ERROR 42S22: Unknown column 'myisam_sort_buffer_size' in 'field list' +SET @@global.myisam_sort_buffer_size = @start_global_value; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +8388608 +SET @@session.myisam_sort_buffer_size = @start_session_value; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +8388608 diff --git a/mysql-test/r/myisam_sort_buffer_size_basic_64.result b/mysql-test/r/myisam_sort_buffer_size_basic_64.result new file mode 100644 index 00000000000..bfcada76a46 --- /dev/null +++ b/mysql-test/r/myisam_sort_buffer_size_basic_64.result @@ -0,0 +1,182 @@ +SET @start_global_value = @@global.myisam_sort_buffer_size ; +SELECT @start_global_value; +@start_global_value +8388608 +SET @start_session_value = @@session.myisam_sort_buffer_size ; +SELECT @start_session_value; +@start_session_value +8388608 +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.myisam_sort_buffer_size = 100; +SET @@global.myisam_sort_buffer_size = DEFAULT; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +8388608 +SET @@session.myisam_sort_buffer_size = 200; +SET @@session.myisam_sort_buffer_size = DEFAULT; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +8388608 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.myisam_sort_buffer_size = DEFAULT; +SELECT @@global.myisam_sort_buffer_size = 8388608; +@@global.myisam_sort_buffer_size = 8388608 +1 +SET @@session.myisam_sort_buffer_size = DEFAULT; +SELECT @@session.myisam_sort_buffer_size = 8388608; +@@session.myisam_sort_buffer_size = 8388608 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.myisam_sort_buffer_size = 4; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +SET @@global.myisam_sort_buffer_size = 4294967295; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4294967295 +SET @@global.myisam_sort_buffer_size = 655354; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +655354 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.myisam_sort_buffer_size = 4; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_sort_buffer_size = 4294967295; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4294967295 +SET @@session.myisam_sort_buffer_size = 655345; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +655345 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.myisam_sort_buffer_size = 0; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +SET @@global.myisam_sort_buffer_size = -1024; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +SET @@global.myisam_sort_buffer_size = 429496729533; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +429496729533 +SET @@global.myisam_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 +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +429496729533 +SET @@global.myisam_sort_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +429496729533 +SET @@global.myisam_sort_buffer_size = "test"; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +429496729533 +SET @@global.myisam_sort_buffer_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +429496729533 +SET @@global.myisam_sort_buffer_size = ON; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +429496729533 +SET @@session.myisam_sort_buffer_size = 0; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_sort_buffer_size = -2; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_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 +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_sort_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +SET @@session.myisam_sort_buffer_size = "test"; +ERROR 42000: Incorrect argument type to variable 'myisam_sort_buffer_size' +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +4 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.myisam_sort_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='myisam_sort_buffer_size '; +@@global.myisam_sort_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.myisam_sort_buffer_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='myisam_sort_buffer_size '; +@@session.myisam_sort_buffer_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_08-----------------------#' +SET @@global.myisam_sort_buffer_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '1' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +SET @@global.myisam_sort_buffer_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '0' +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +4 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.myisam_sort_buffer_size = 10; +SELECT @@myisam_sort_buffer_size = @@global.myisam_sort_buffer_size ; +@@myisam_sort_buffer_size = @@global.myisam_sort_buffer_size +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@myisam_sort_buffer_size = 100; +SELECT @@myisam_sort_buffer_size = @@local.myisam_sort_buffer_size ; +@@myisam_sort_buffer_size = @@local.myisam_sort_buffer_size +1 +SELECT @@local.myisam_sort_buffer_size = @@session.myisam_sort_buffer_size ; +@@local.myisam_sort_buffer_size = @@session.myisam_sort_buffer_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET myisam_sort_buffer_size = 1; +Warnings: +Warning 1292 Truncated incorrect myisam_sort_buffer_size value: '1' +SELECT @@myisam_sort_buffer_size ; +@@myisam_sort_buffer_size +4 +SELECT local.myisam_sort_buffer_size ; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.myisam_sort_buffer_size ; +ERROR 42S02: Unknown table 'session' in field list +SELECT myisam_sort_buffer_size = @@session.myisam_sort_buffer_size ; +ERROR 42S22: Unknown column 'myisam_sort_buffer_size' in 'field list' +SET @@global.myisam_sort_buffer_size = @start_global_value; +SELECT @@global.myisam_sort_buffer_size ; +@@global.myisam_sort_buffer_size +8388608 +SET @@session.myisam_sort_buffer_size = @start_session_value; +SELECT @@session.myisam_sort_buffer_size ; +@@session.myisam_sort_buffer_size +8388608 diff --git a/mysql-test/r/net_retry_count_basic_32.result b/mysql-test/r/net_retry_count_basic_32.result new file mode 100644 index 00000000000..3923df539e7 --- /dev/null +++ b/mysql-test/r/net_retry_count_basic_32.result @@ -0,0 +1,192 @@ +SET @start_global_value = @@global.net_retry_count; +SELECT @start_global_value; +@start_global_value +10 +SET @start_session_value = @@session.net_retry_count; +SELECT @start_session_value; +@start_session_value +10 +'#--------------------FN_DYNVARS_111_01-------------------------#' +SET @@global.net_retry_count = 100; +SET @@global.net_retry_count = DEFAULT; +SELECT @@global.net_retry_count; +@@global.net_retry_count +10 +SET @@session.net_retry_count = 200; +SET @@session.net_retry_count = DEFAULT; +SELECT @@session.net_retry_count; +@@session.net_retry_count +10 +'#--------------------FN_DYNVARS_111_02-------------------------#' +SET @@global.net_retry_count = DEFAULT; +SELECT @@global.net_retry_count = 10; +@@global.net_retry_count = 10 +1 +SET @@session.net_retry_count = DEFAULT; +SELECT @@session.net_retry_count = 10; +@@session.net_retry_count = 10 +1 +'#--------------------FN_DYNVARS_111_03-------------------------#' +SET @@global.net_retry_count = 1; +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +SET @@global.net_retry_count = 2; +SELECT @@global.net_retry_count; +@@global.net_retry_count +2 +SET @@global.net_retry_count = 4294967295; +SELECT @@global.net_retry_count; +@@global.net_retry_count +4294967295 +SET @@global.net_retry_count = 4294967294; +SELECT @@global.net_retry_count; +@@global.net_retry_count +4294967294 +SET @@global.net_retry_count = 65536; +SELECT @@global.net_retry_count; +@@global.net_retry_count +65536 +'#--------------------FN_DYNVARS_111_04-------------------------#' +SET @@session.net_retry_count = 1; +SELECT @@session.net_retry_count; +@@session.net_retry_count +1 +SET @@session.net_retry_count = 2; +SELECT @@session.net_retry_count; +@@session.net_retry_count +2 +SET @@session.net_retry_count = 65535; +SELECT @@session.net_retry_count; +@@session.net_retry_count +65535 +SET @@session.net_retry_count = 4294967295; +SELECT @@session.net_retry_count; +@@session.net_retry_count +4294967295 +SET @@session.net_retry_count = 4294967294; +SELECT @@session.net_retry_count; +@@session.net_retry_count +4294967294 +'#------------------FN_DYNVARS_111_05-----------------------#' +SET @@global.net_retry_count = 0; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +SET @@global.net_retry_count = -1024; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +SET @@global.net_retry_count = 4294967296; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '4294967296' +SELECT @@global.net_retry_count; +@@global.net_retry_count +4294967295 +SET @@global.net_retry_count = 429496729500; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '429496729500' +SELECT @@global.net_retry_count; +@@global.net_retry_count +4294967295 +SET @@global.net_retry_count = 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 +SELECT @@global.net_retry_count; +@@global.net_retry_count +4294967295 +SET @@global.net_retry_count = test; +ERROR 42000: Incorrect argument type to variable 'net_retry_count' +SELECT @@global.net_retry_count; +@@global.net_retry_count +4294967295 +SET @@session.net_retry_count = 0; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@session.net_retry_count; +@@session.net_retry_count +1 +SET @@session.net_retry_count = -2; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@session.net_retry_count; +@@session.net_retry_count +1 +SET @@session.net_retry_count = 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.net_retry_count = 6555015425; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '6555015425' +SELECT @@session.net_retry_count; +@@session.net_retry_count +4294967295 +SET @@session.net_retry_count = 4294967296; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '4294967296' +SELECT @@session.net_retry_count; +@@session.net_retry_count +4294967295 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.net_retry_count = test; +ERROR 42000: Incorrect argument type to variable 'net_retry_count' +SELECT @@session.net_retry_count; +@@session.net_retry_count +4294967295 +'#------------------FN_DYNVARS_111_06-----------------------#' +SELECT @@global.net_retry_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='net_retry_count'; +@@global.net_retry_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_111_07-----------------------#' +SELECT @@session.net_retry_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='net_retry_count'; +@@session.net_retry_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_111_08-----------------------#' +SET @@global.net_retry_count = TRUE; +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +SET @@global.net_retry_count = FALSE; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +'#---------------------FN_DYNVARS_111_09----------------------#' +SET @@global.net_retry_count = 10; +SELECT @@net_retry_count = @@global.net_retry_count; +@@net_retry_count = @@global.net_retry_count +0 +'#---------------------FN_DYNVARS_111_10----------------------#' +SET @@net_retry_count = 100; +SELECT @@net_retry_count = @@local.net_retry_count; +@@net_retry_count = @@local.net_retry_count +1 +SELECT @@local.net_retry_count = @@session.net_retry_count; +@@local.net_retry_count = @@session.net_retry_count +1 +'#---------------------FN_DYNVARS_111_11----------------------#' +SET net_retry_count = 1; +SELECT @@net_retry_count; +@@net_retry_count +1 +SELECT local.net_retry_count; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.net_retry_count; +ERROR 42S02: Unknown table 'session' in field list +SELECT net_retry_count = @@session.net_retry_count; +ERROR 42S22: Unknown column 'net_retry_count' in 'field list' +SET @@global.net_retry_count = @start_global_value; +SELECT @@global.net_retry_count; +@@global.net_retry_count +10 +SET @@session.net_retry_count = @start_session_value; +SELECT @@session.net_retry_count; +@@session.net_retry_count +10 diff --git a/mysql-test/r/net_retry_count_basic_64.result b/mysql-test/r/net_retry_count_basic_64.result new file mode 100644 index 00000000000..db133d23f79 --- /dev/null +++ b/mysql-test/r/net_retry_count_basic_64.result @@ -0,0 +1,184 @@ +SET @start_global_value = @@global.net_retry_count; +SELECT @start_global_value; +@start_global_value +10 +SET @start_session_value = @@session.net_retry_count; +SELECT @start_session_value; +@start_session_value +10 +'#--------------------FN_DYNVARS_111_01-------------------------#' +SET @@global.net_retry_count = 100; +SET @@global.net_retry_count = DEFAULT; +SELECT @@global.net_retry_count; +@@global.net_retry_count +10 +SET @@session.net_retry_count = 200; +SET @@session.net_retry_count = DEFAULT; +SELECT @@session.net_retry_count; +@@session.net_retry_count +10 +'#--------------------FN_DYNVARS_111_02-------------------------#' +SET @@global.net_retry_count = DEFAULT; +SELECT @@global.net_retry_count = 10; +@@global.net_retry_count = 10 +1 +SET @@session.net_retry_count = DEFAULT; +SELECT @@session.net_retry_count = 10; +@@session.net_retry_count = 10 +1 +'#--------------------FN_DYNVARS_111_03-------------------------#' +SET @@global.net_retry_count = 1; +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +SET @@global.net_retry_count = 2; +SELECT @@global.net_retry_count; +@@global.net_retry_count +2 +SET @@global.net_retry_count = 4294967295; +SELECT @@global.net_retry_count; +@@global.net_retry_count +4294967295 +SET @@global.net_retry_count = 4294967294; +SELECT @@global.net_retry_count; +@@global.net_retry_count +4294967294 +SET @@global.net_retry_count = 65536; +SELECT @@global.net_retry_count; +@@global.net_retry_count +65536 +'#--------------------FN_DYNVARS_111_04-------------------------#' +SET @@session.net_retry_count = 1; +SELECT @@session.net_retry_count; +@@session.net_retry_count +1 +SET @@session.net_retry_count = 2; +SELECT @@session.net_retry_count; +@@session.net_retry_count +2 +SET @@session.net_retry_count = 65535; +SELECT @@session.net_retry_count; +@@session.net_retry_count +65535 +SET @@session.net_retry_count = 4294967295; +SELECT @@session.net_retry_count; +@@session.net_retry_count +4294967295 +SET @@session.net_retry_count = 4294967294; +SELECT @@session.net_retry_count; +@@session.net_retry_count +4294967294 +'#------------------FN_DYNVARS_111_05-----------------------#' +SET @@global.net_retry_count = 0; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +SET @@global.net_retry_count = -1024; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +SET @@global.net_retry_count = 4294967296; +SELECT @@global.net_retry_count; +@@global.net_retry_count +4294967296 +SET @@global.net_retry_count = 429496729500; +SELECT @@global.net_retry_count; +@@global.net_retry_count +429496729500 +SET @@global.net_retry_count = 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 +SELECT @@global.net_retry_count; +@@global.net_retry_count +429496729500 +SET @@global.net_retry_count = test; +ERROR 42000: Incorrect argument type to variable 'net_retry_count' +SELECT @@global.net_retry_count; +@@global.net_retry_count +429496729500 +SET @@session.net_retry_count = 0; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@session.net_retry_count; +@@session.net_retry_count +1 +SET @@session.net_retry_count = -2; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@session.net_retry_count; +@@session.net_retry_count +1 +SET @@session.net_retry_count = 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.net_retry_count = 6555015425; +SELECT @@session.net_retry_count; +@@session.net_retry_count +6555015425 +SET @@session.net_retry_count = 4294967296; +SELECT @@session.net_retry_count; +@@session.net_retry_count +4294967296 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.net_retry_count = test; +ERROR 42000: Incorrect argument type to variable 'net_retry_count' +SELECT @@session.net_retry_count; +@@session.net_retry_count +4294967296 +'#------------------FN_DYNVARS_111_06-----------------------#' +SELECT @@global.net_retry_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='net_retry_count'; +@@global.net_retry_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_111_07-----------------------#' +SELECT @@session.net_retry_count = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='net_retry_count'; +@@session.net_retry_count = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_111_08-----------------------#' +SET @@global.net_retry_count = TRUE; +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +SET @@global.net_retry_count = FALSE; +Warnings: +Warning 1292 Truncated incorrect net_retry_count value: '0' +SELECT @@global.net_retry_count; +@@global.net_retry_count +1 +'#---------------------FN_DYNVARS_111_09----------------------#' +SET @@global.net_retry_count = 10; +SELECT @@net_retry_count = @@global.net_retry_count; +@@net_retry_count = @@global.net_retry_count +0 +'#---------------------FN_DYNVARS_111_10----------------------#' +SET @@net_retry_count = 100; +SELECT @@net_retry_count = @@local.net_retry_count; +@@net_retry_count = @@local.net_retry_count +1 +SELECT @@local.net_retry_count = @@session.net_retry_count; +@@local.net_retry_count = @@session.net_retry_count +1 +'#---------------------FN_DYNVARS_111_11----------------------#' +SET net_retry_count = 1; +SELECT @@net_retry_count; +@@net_retry_count +1 +SELECT local.net_retry_count; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.net_retry_count; +ERROR 42S02: Unknown table 'session' in field list +SELECT net_retry_count = @@session.net_retry_count; +ERROR 42S22: Unknown column 'net_retry_count' in 'field list' +SET @@global.net_retry_count = @start_global_value; +SELECT @@global.net_retry_count; +@@global.net_retry_count +10 +SET @@session.net_retry_count = @start_session_value; +SELECT @@session.net_retry_count; +@@session.net_retry_count +10 diff --git a/mysql-test/r/query_alloc_block_size_basic_32.result b/mysql-test/r/query_alloc_block_size_basic_32.result new file mode 100644 index 00000000000..3b7f06c8f81 --- /dev/null +++ b/mysql-test/r/query_alloc_block_size_basic_32.result @@ -0,0 +1,203 @@ +SET @start_global_value = @@global.query_alloc_block_size; +SELECT @start_global_value; +@start_global_value +8192 +SET @start_session_value = @@session.query_alloc_block_size; +SELECT @start_session_value; +@start_session_value +8192 +'#--------------------FN_DYNVARS_130_01-------------------------#' +SET @@global.query_alloc_block_size = 10000; +SET @@global.query_alloc_block_size = DEFAULT; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +8192 +SET @@session.query_alloc_block_size = 20000; +SET @@session.query_alloc_block_size = DEFAULT; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +8192 +'#--------------------FN_DYNVARS_130_02-------------------------#' +SET @@global.query_alloc_block_size = DEFAULT; +SELECT @@global.query_alloc_block_size = 8192; +@@global.query_alloc_block_size = 8192 +1 +SET @@session.query_alloc_block_size = DEFAULT; +SELECT @@session.query_alloc_block_size = 8192; +@@session.query_alloc_block_size = 8192 +1 +'#--------------------FN_DYNVARS_130_03-------------------------#' +SET @@global.query_alloc_block_size = 1024; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = 1025; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = 4294967295; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294966272 +SET @@global.query_alloc_block_size = 4294967294; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294966272 +SET @@global.query_alloc_block_size = 65536; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +65536 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_130_04-------------------------#' +SET @@session.query_alloc_block_size = 1024; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_size = 1025; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_size = 4294967295; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +4294966272 +SET @@session.query_alloc_block_size = 4294967294; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +4294966272 +SET @@session.query_alloc_block_size = 655536; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +655360 +'#------------------FN_DYNVARS_130_05-----------------------#' +SET @@global.query_alloc_block_size = 64; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '64' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = -1; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '0' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = 1023; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '1023' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = 4294967296; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '4294967296' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294966272 +SET @@global.query_alloc_block_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 +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294966272 +SET @@global.query_alloc_block_size = test; +ERROR 42000: Incorrect argument type to variable 'query_alloc_block_size' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294966272 +SET @@session.query_alloc_block_size = 64; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '64' +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_size = -2; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '0' +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_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.query_alloc_block_size = 1023; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '1023' +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_size = 4294967296; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '4294967296' +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +4294966272 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.query_alloc_block_size = test; +ERROR 42000: Incorrect argument type to variable 'query_alloc_block_size' +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +4294966272 +'#------------------FN_DYNVARS_130_06-----------------------#' +'Bug# 34877: OutOFMemeory errors are coming if we dont assign these values to variable before comparision statement'; +SET @@global.query_alloc_block_size = 1; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '1' +SET @@session.query_alloc_block_size = 12; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '12' +SELECT @@global.query_alloc_block_size = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_alloc_block_size'; +@@global.query_alloc_block_size = +VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_130_07-----------------------#' +SELECT @@session.query_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_alloc_block_size'; +@@session.query_alloc_block_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_130_08-----------------------#' +SET @@global.query_alloc_block_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '1' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '0' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +'#---------------------FN_DYNVARS_130_09----------------------#' +SET @@global.query_alloc_block_size = 2048; +SELECT @@query_alloc_block_size = @@global.query_alloc_block_size; +@@query_alloc_block_size = @@global.query_alloc_block_size +0 +'#---------------------FN_DYNVARS_130_10----------------------#' +SET @@query_alloc_block_size = 5000; +SELECT @@query_alloc_block_size = @@local.query_alloc_block_size; +@@query_alloc_block_size = @@local.query_alloc_block_size +1 +SELECT @@local.query_alloc_block_size = @@session.query_alloc_block_size; +@@local.query_alloc_block_size = @@session.query_alloc_block_size +1 +'#---------------------FN_DYNVARS_130_11----------------------#' +SET query_alloc_block_size = 1024; +SELECT @@query_alloc_block_size; +@@query_alloc_block_size +1024 +SELECT local.query_alloc_block_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.query_alloc_block_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT query_alloc_block_size = @@session.query_alloc_block_size; +ERROR 42S22: Unknown column 'query_alloc_block_size' in 'field list' +SET @@global.query_alloc_block_size = @start_global_value; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +8192 +SET @@session.query_alloc_block_size = @start_session_value; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +8192 diff --git a/mysql-test/r/query_alloc_block_size_basic_64.result b/mysql-test/r/query_alloc_block_size_basic_64.result new file mode 100644 index 00000000000..57c96a8168a --- /dev/null +++ b/mysql-test/r/query_alloc_block_size_basic_64.result @@ -0,0 +1,199 @@ +SET @start_global_value = @@global.query_alloc_block_size; +SELECT @start_global_value; +@start_global_value +8192 +SET @start_session_value = @@session.query_alloc_block_size; +SELECT @start_session_value; +@start_session_value +8192 +'#--------------------FN_DYNVARS_130_01-------------------------#' +SET @@global.query_alloc_block_size = 10000; +SET @@global.query_alloc_block_size = DEFAULT; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +8192 +SET @@session.query_alloc_block_size = 20000; +SET @@session.query_alloc_block_size = DEFAULT; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +8192 +'#--------------------FN_DYNVARS_130_02-------------------------#' +SET @@global.query_alloc_block_size = DEFAULT; +SELECT @@global.query_alloc_block_size = 8192; +@@global.query_alloc_block_size = 8192 +1 +SET @@session.query_alloc_block_size = DEFAULT; +SELECT @@session.query_alloc_block_size = 8192; +@@session.query_alloc_block_size = 8192 +1 +'#--------------------FN_DYNVARS_130_03-------------------------#' +SET @@global.query_alloc_block_size = 1024; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = 1025; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = 4294967295; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294966272 +SET @@global.query_alloc_block_size = 4294967294; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294966272 +SET @@global.query_alloc_block_size = 65536; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +65536 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_130_04-------------------------#' +SET @@session.query_alloc_block_size = 1024; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_size = 1025; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_size = 4294967295; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +4294966272 +SET @@session.query_alloc_block_size = 4294967294; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +4294966272 +SET @@session.query_alloc_block_size = 655536; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +655360 +'#------------------FN_DYNVARS_130_05-----------------------#' +SET @@global.query_alloc_block_size = 64; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '64' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = -1; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '0' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = 1023; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '1023' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = 4294967296; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294967296 +SET @@global.query_alloc_block_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 +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294967296 +SET @@global.query_alloc_block_size = test; +ERROR 42000: Incorrect argument type to variable 'query_alloc_block_size' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +4294967296 +SET @@session.query_alloc_block_size = 64; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '64' +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_size = -2; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '0' +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_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.query_alloc_block_size = 1023; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '1023' +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +1024 +SET @@session.query_alloc_block_size = 4294967296; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +4294967296 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.query_alloc_block_size = test; +ERROR 42000: Incorrect argument type to variable 'query_alloc_block_size' +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +4294967296 +'#------------------FN_DYNVARS_130_06-----------------------#' +'Bug# 34877: OutOFMemeory errors are coming if we dont assign these values to variable before comparision statement'; +SET @@global.query_alloc_block_size = 1; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '1' +SET @@session.query_alloc_block_size = 12; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '12' +SELECT @@global.query_alloc_block_size = +VARIABLE_VALUE FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_alloc_block_size'; +@@global.query_alloc_block_size = +VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_130_07-----------------------#' +SELECT @@session.query_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_alloc_block_size'; +@@session.query_alloc_block_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_130_08-----------------------#' +SET @@global.query_alloc_block_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '1' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +SET @@global.query_alloc_block_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect query_alloc_block_size value: '0' +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +1024 +'#---------------------FN_DYNVARS_130_09----------------------#' +SET @@global.query_alloc_block_size = 2048; +SELECT @@query_alloc_block_size = @@global.query_alloc_block_size; +@@query_alloc_block_size = @@global.query_alloc_block_size +0 +'#---------------------FN_DYNVARS_130_10----------------------#' +SET @@query_alloc_block_size = 5000; +SELECT @@query_alloc_block_size = @@local.query_alloc_block_size; +@@query_alloc_block_size = @@local.query_alloc_block_size +1 +SELECT @@local.query_alloc_block_size = @@session.query_alloc_block_size; +@@local.query_alloc_block_size = @@session.query_alloc_block_size +1 +'#---------------------FN_DYNVARS_130_11----------------------#' +SET query_alloc_block_size = 1024; +SELECT @@query_alloc_block_size; +@@query_alloc_block_size +1024 +SELECT local.query_alloc_block_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.query_alloc_block_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT query_alloc_block_size = @@session.query_alloc_block_size; +ERROR 42S22: Unknown column 'query_alloc_block_size' in 'field list' +SET @@global.query_alloc_block_size = @start_global_value; +SELECT @@global.query_alloc_block_size; +@@global.query_alloc_block_size +8192 +SET @@session.query_alloc_block_size = @start_session_value; +SELECT @@session.query_alloc_block_size; +@@session.query_alloc_block_size +8192 diff --git a/mysql-test/r/query_cache_limit_basic_32.result b/mysql-test/r/query_cache_limit_basic_32.result new file mode 100644 index 00000000000..bb66233732d --- /dev/null +++ b/mysql-test/r/query_cache_limit_basic_32.result @@ -0,0 +1,126 @@ +SET @start_value = @@global.query_cache_limit; +SELECT @start_value; +@start_value +1048576 +'#--------------------FN_DYNVARS_131_01------------------------#' +SET @@global.query_cache_limit = 99; +SET @@global.query_cache_limit = DEFAULT; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1048576 +'#---------------------FN_DYNVARS_131_02-------------------------#' +SET @@global.query_cache_limit = @start_value; +SELECT @@global.query_cache_limit = 1048576; +@@global.query_cache_limit = 1048576 +1 +'#--------------------FN_DYNVARS_131_03------------------------#' +SET @@global.query_cache_limit = 0; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +0 +SET @@global.query_cache_limit = 1; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1 +SET @@global.query_cache_limit = 1048576; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1048576 +SET @@global.query_cache_limit = 1048575; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1048575 +'#--------------------FN_DYNVARS_131_04-------------------------#' +SET @@global.query_cache_limit = -1; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +0 +SET @@global.query_cache_limit = 4294967296; +Warnings: +Warning 1292 Truncated incorrect query_cache_limit value: '4294967296' +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +4294967295 +SET @@global.query_cache_limit = 10240022115; +Warnings: +Warning 1292 Truncated incorrect query_cache_limit value: '10240022115' +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +4294967295 +SET @@global.query_cache_limit = 10000.01; +ERROR 42000: Incorrect argument type to variable 'query_cache_limit' +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +4294967295 +SET @@global.query_cache_limit = -1024; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +0 +SET @@global.query_cache_limit = 42949672950; +Warnings: +Warning 1292 Truncated incorrect query_cache_limit value: '42949672950' +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +4294967295 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.query_cache_limit = ON; +ERROR 42000: Incorrect argument type to variable 'query_cache_limit' +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +4294967295 +SET @@global.query_cache_limit = 'test'; +ERROR 42000: Incorrect argument type to variable 'query_cache_limit' +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +4294967295 +'#-------------------FN_DYNVARS_131_05----------------------------#' +SET @@session.query_cache_limit = 0; +ERROR HY000: Variable 'query_cache_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_limit; +@@query_cache_limit +4294967295 +'#----------------------FN_DYNVARS_131_06------------------------#' +SELECT @@global.query_cache_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_cache_limit'; +@@global.query_cache_limit = VARIABLE_VALUE +1 +SELECT @@query_cache_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_cache_limit'; +@@query_cache_limit = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_131_07----------------------#' +SET @@global.query_cache_limit = TRUE; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1 +SET @@global.query_cache_limit = FALSE; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +0 +'#---------------------FN_DYNVARS_131_08----------------------#' +SET @@global.query_cache_limit = 1; +SELECT @@query_cache_limit = @@global.query_cache_limit; +@@query_cache_limit = @@global.query_cache_limit +1 +'#---------------------FN_DYNVARS_131_09----------------------#' +SET query_cache_limit = 1; +ERROR HY000: Variable 'query_cache_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_limit; +@@query_cache_limit +1 +SET local.query_cache_limit = 1; +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 'query_cache_limit = 1' at line 1 +SELECT local.query_cache_limit; +ERROR 42S02: Unknown table 'local' in field list +SET global.query_cache_limit = 1; +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 'query_cache_limit = 1' at line 1 +SELECT global.query_cache_limit; +ERROR 42S02: Unknown table 'global' in field list +SELECT query_cache_limit = @@session.query_cache_limit; +ERROR 42S22: Unknown column 'query_cache_limit' in 'field list' +SET @@global.query_cache_limit = @start_value; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1048576 diff --git a/mysql-test/r/query_cache_limit_basic_64.result b/mysql-test/r/query_cache_limit_basic_64.result new file mode 100644 index 00000000000..a592883ef91 --- /dev/null +++ b/mysql-test/r/query_cache_limit_basic_64.result @@ -0,0 +1,120 @@ +SET @start_value = @@global.query_cache_limit; +SELECT @start_value; +@start_value +1048576 +'#--------------------FN_DYNVARS_131_01------------------------#' +SET @@global.query_cache_limit = 99; +SET @@global.query_cache_limit = DEFAULT; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1048576 +'#---------------------FN_DYNVARS_131_02-------------------------#' +SET @@global.query_cache_limit = @start_value; +SELECT @@global.query_cache_limit = 1048576; +@@global.query_cache_limit = 1048576 +1 +'#--------------------FN_DYNVARS_131_03------------------------#' +SET @@global.query_cache_limit = 0; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +0 +SET @@global.query_cache_limit = 1; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1 +SET @@global.query_cache_limit = 1048576; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1048576 +SET @@global.query_cache_limit = 1048575; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1048575 +'#--------------------FN_DYNVARS_131_04-------------------------#' +SET @@global.query_cache_limit = -1; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +0 +SET @@global.query_cache_limit = 4294967296; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +4294967296 +SET @@global.query_cache_limit = 10240022115; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +10240022115 +SET @@global.query_cache_limit = 10000.01; +ERROR 42000: Incorrect argument type to variable 'query_cache_limit' +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +10240022115 +SET @@global.query_cache_limit = -1024; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +0 +SET @@global.query_cache_limit = 42949672950; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +42949672950 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.query_cache_limit = ON; +ERROR 42000: Incorrect argument type to variable 'query_cache_limit' +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +42949672950 +SET @@global.query_cache_limit = 'test'; +ERROR 42000: Incorrect argument type to variable 'query_cache_limit' +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +42949672950 +'#-------------------FN_DYNVARS_131_05----------------------------#' +SET @@session.query_cache_limit = 0; +ERROR HY000: Variable 'query_cache_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_limit; +@@query_cache_limit +42949672950 +'#----------------------FN_DYNVARS_131_06------------------------#' +SELECT @@global.query_cache_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_cache_limit'; +@@global.query_cache_limit = VARIABLE_VALUE +1 +SELECT @@query_cache_limit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_cache_limit'; +@@query_cache_limit = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_131_07----------------------#' +SET @@global.query_cache_limit = TRUE; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1 +SET @@global.query_cache_limit = FALSE; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +0 +'#---------------------FN_DYNVARS_131_08----------------------#' +SET @@global.query_cache_limit = 1; +SELECT @@query_cache_limit = @@global.query_cache_limit; +@@query_cache_limit = @@global.query_cache_limit +1 +'#---------------------FN_DYNVARS_131_09----------------------#' +SET query_cache_limit = 1; +ERROR HY000: Variable 'query_cache_limit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_limit; +@@query_cache_limit +1 +SET local.query_cache_limit = 1; +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 'query_cache_limit = 1' at line 1 +SELECT local.query_cache_limit; +ERROR 42S02: Unknown table 'local' in field list +SET global.query_cache_limit = 1; +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 'query_cache_limit = 1' at line 1 +SELECT global.query_cache_limit; +ERROR 42S02: Unknown table 'global' in field list +SELECT query_cache_limit = @@session.query_cache_limit; +ERROR 42S22: Unknown column 'query_cache_limit' in 'field list' +SET @@global.query_cache_limit = @start_value; +SELECT @@global.query_cache_limit; +@@global.query_cache_limit +1048576 diff --git a/mysql-test/r/query_cache_min_res_unit_basic_32.result b/mysql-test/r/query_cache_min_res_unit_basic_32.result new file mode 100644 index 00000000000..e0d8a0d2a30 --- /dev/null +++ b/mysql-test/r/query_cache_min_res_unit_basic_32.result @@ -0,0 +1,134 @@ +SET @start_value = @@global.query_cache_min_res_unit; +SELECT @start_value; +@start_value +4096 +'#--------------------FN_DYNVARS_132_01------------------------#' +SET @@global.query_cache_min_res_unit = 99; +SET @@global.query_cache_min_res_unit = DEFAULT; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +4096 +'#---------------------FN_DYNVARS_132_02-------------------------#' +SET @@global.query_cache_min_res_unit = @start_value; +SELECT @@global.query_cache_min_res_unit = 4096; +@@global.query_cache_min_res_unit = 4096 +1 +'#--------------------FN_DYNVARS_132_03------------------------#' +SET @@global.query_cache_min_res_unit = 0; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 1; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +'Bug#34842: FN_DYNVARS_132_03 - Minimum value according to documentation is 0, and here it is 512'; +SET @@global.query_cache_min_res_unit = 512; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 513; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +520 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.query_cache_min_res_unit = 1048576; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +1048576 +SET @@global.query_cache_min_res_unit = 1048575; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +1048576 +'#--------------------FN_DYNVARS_132_04-------------------------#' +SET @@global.query_cache_min_res_unit = -1; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 4294967296; +Warnings: +Warning 1292 Truncated incorrect query_cache_min_res_unit value: '4294967296' +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +0 +SET @@global.query_cache_min_res_unit = 511; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 10000.01; +ERROR 42000: Incorrect argument type to variable 'query_cache_min_res_unit' +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = -1024; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 42949672950; +Warnings: +Warning 1292 Truncated incorrect query_cache_min_res_unit value: '42949672950' +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +0 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.query_cache_min_res_unit = ON; +ERROR 42000: Incorrect argument type to variable 'query_cache_min_res_unit' +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +0 +SET @@global.query_cache_min_res_unit = 'test'; +ERROR 42000: Incorrect argument type to variable 'query_cache_min_res_unit' +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +0 +'#-------------------FN_DYNVARS_132_05----------------------------#' +SET @@session.query_cache_min_res_unit = 0; +ERROR HY000: Variable 'query_cache_min_res_unit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_min_res_unit; +@@query_cache_min_res_unit +0 +'#----------------------FN_DYNVARS_132_06------------------------#' +SELECT @@global.query_cache_min_res_unit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_cache_min_res_unit'; +@@global.query_cache_min_res_unit = VARIABLE_VALUE +1 +SELECT @@query_cache_min_res_unit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_cache_min_res_unit'; +@@query_cache_min_res_unit = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_132_07----------------------#' +SET @@global.query_cache_min_res_unit = TRUE; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = FALSE; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +'#---------------------FN_DYNVARS_132_08----------------------#' +SET @@global.query_cache_min_res_unit = 1; +SELECT @@query_cache_min_res_unit = @@global.query_cache_min_res_unit; +@@query_cache_min_res_unit = @@global.query_cache_min_res_unit +1 +'#---------------------FN_DYNVARS_132_09----------------------#' +SET query_cache_min_res_unit = 1; +ERROR HY000: Variable 'query_cache_min_res_unit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_min_res_unit; +@@query_cache_min_res_unit +512 +SET local.query_cache_min_res_unit = 1; +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 'query_cache_min_res_unit = 1' at line 1 +SELECT local.query_cache_min_res_unit; +ERROR 42S02: Unknown table 'local' in field list +SET global.query_cache_min_res_unit = 1; +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 'query_cache_min_res_unit = 1' at line 1 +SELECT global.query_cache_min_res_unit; +ERROR 42S02: Unknown table 'global' in field list +SELECT query_cache_min_res_unit = @@session.query_cache_min_res_unit; +ERROR 42S22: Unknown column 'query_cache_min_res_unit' in 'field list' +SET @@global.query_cache_min_res_unit = @start_value; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +4096 diff --git a/mysql-test/r/query_cache_min_res_unit_basic_64.result b/mysql-test/r/query_cache_min_res_unit_basic_64.result new file mode 100644 index 00000000000..e1c74d2bbc1 --- /dev/null +++ b/mysql-test/r/query_cache_min_res_unit_basic_64.result @@ -0,0 +1,130 @@ +SET @start_value = @@global.query_cache_min_res_unit; +SELECT @start_value; +@start_value +4096 +'#--------------------FN_DYNVARS_132_01------------------------#' +SET @@global.query_cache_min_res_unit = 99; +SET @@global.query_cache_min_res_unit = DEFAULT; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +4096 +'#---------------------FN_DYNVARS_132_02-------------------------#' +SET @@global.query_cache_min_res_unit = @start_value; +SELECT @@global.query_cache_min_res_unit = 4096; +@@global.query_cache_min_res_unit = 4096 +1 +'#--------------------FN_DYNVARS_132_03------------------------#' +SET @@global.query_cache_min_res_unit = 0; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 1; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +'Bug#34842: FN_DYNVARS_132_03 - Minimum value according to documentation is 0, and here it is 512'; +SET @@global.query_cache_min_res_unit = 512; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 513; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +520 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.query_cache_min_res_unit = 1048576; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +1048576 +SET @@global.query_cache_min_res_unit = 1048575; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +1048576 +'#--------------------FN_DYNVARS_132_04-------------------------#' +SET @@global.query_cache_min_res_unit = -1; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 4294967296; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +4294967296 +SET @@global.query_cache_min_res_unit = 511; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 10000.01; +ERROR 42000: Incorrect argument type to variable 'query_cache_min_res_unit' +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = -1024; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = 42949672950; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +42949672952 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.query_cache_min_res_unit = ON; +ERROR 42000: Incorrect argument type to variable 'query_cache_min_res_unit' +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +42949672952 +SET @@global.query_cache_min_res_unit = 'test'; +ERROR 42000: Incorrect argument type to variable 'query_cache_min_res_unit' +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +42949672952 +'#-------------------FN_DYNVARS_132_05----------------------------#' +SET @@session.query_cache_min_res_unit = 0; +ERROR HY000: Variable 'query_cache_min_res_unit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_min_res_unit; +@@query_cache_min_res_unit +42949672952 +'#----------------------FN_DYNVARS_132_06------------------------#' +SELECT @@global.query_cache_min_res_unit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_cache_min_res_unit'; +@@global.query_cache_min_res_unit = VARIABLE_VALUE +1 +SELECT @@query_cache_min_res_unit = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_cache_min_res_unit'; +@@query_cache_min_res_unit = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_132_07----------------------#' +SET @@global.query_cache_min_res_unit = TRUE; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +SET @@global.query_cache_min_res_unit = FALSE; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +512 +'#---------------------FN_DYNVARS_132_08----------------------#' +SET @@global.query_cache_min_res_unit = 1; +SELECT @@query_cache_min_res_unit = @@global.query_cache_min_res_unit; +@@query_cache_min_res_unit = @@global.query_cache_min_res_unit +1 +'#---------------------FN_DYNVARS_132_09----------------------#' +SET query_cache_min_res_unit = 1; +ERROR HY000: Variable 'query_cache_min_res_unit' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_min_res_unit; +@@query_cache_min_res_unit +512 +SET local.query_cache_min_res_unit = 1; +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 'query_cache_min_res_unit = 1' at line 1 +SELECT local.query_cache_min_res_unit; +ERROR 42S02: Unknown table 'local' in field list +SET global.query_cache_min_res_unit = 1; +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 'query_cache_min_res_unit = 1' at line 1 +SELECT global.query_cache_min_res_unit; +ERROR 42S02: Unknown table 'global' in field list +SELECT query_cache_min_res_unit = @@session.query_cache_min_res_unit; +ERROR 42S22: Unknown column 'query_cache_min_res_unit' in 'field list' +SET @@global.query_cache_min_res_unit = @start_value; +SELECT @@global.query_cache_min_res_unit; +@@global.query_cache_min_res_unit +4096 diff --git a/mysql-test/r/query_cache_size_basic_32.result b/mysql-test/r/query_cache_size_basic_32.result new file mode 100644 index 00000000000..1af70b3af84 --- /dev/null +++ b/mysql-test/r/query_cache_size_basic_32.result @@ -0,0 +1,138 @@ +SET @start_value = @@global.query_cache_size; +SELECT @start_value; +@start_value +0 +'#--------------------FN_DYNVARS_133_01------------------------#' +SET @@global.query_cache_size = 99; +SET @@global.query_cache_size = DEFAULT; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +'#---------------------FN_DYNVARS_133_02-------------------------#' +SET @@global.query_cache_size = @start_value; +SELECT @@global.query_cache_size = 0; +@@global.query_cache_size = 0 +1 +'#--------------------FN_DYNVARS_133_03------------------------#' +SET @@global.query_cache_size = 0; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 1; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 512; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 1024; +Warnings: +Warning 1282 Query cache failed to set size 1024; new query cache size is 0 +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +: 'Bug#34880: Warnings are coming on assinging valid values to variable +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.query_cache_size = 1048576; +SELECT @@global.query_cache_size; +@@global.query_cache_size +1048576 +SET @@global.query_cache_size = 1048575; +SELECT @@global.query_cache_size; +@@global.query_cache_size +1047552 +'#--------------------FN_DYNVARS_133_04-------------------------#' +SET @@global.query_cache_size = -1; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 4294967296; +Warnings: +Warning 1292 Truncated incorrect query_cache_size value: '4294967296' +Warning 1282 Query cache failed to set size 4294966272; new query cache size is 0 +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 511; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'query_cache_size' +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = -1024; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 42949672950; +Warnings: +Warning 1292 Truncated incorrect query_cache_size value: '42949672950' +Warning 1282 Query cache failed to set size 4294966272; new query cache size is 0 +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.query_cache_size = ON; +ERROR 42000: Incorrect argument type to variable 'query_cache_size' +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'query_cache_size' +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +'#-------------------FN_DYNVARS_133_05----------------------------#' +SET @@session.query_cache_size = 0; +ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_size; +@@query_cache_size +0 +'#----------------------FN_DYNVARS_133_06------------------------#' +SELECT @@global.query_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_cache_size'; +@@global.query_cache_size = VARIABLE_VALUE +1 +SELECT @@query_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_cache_size'; +@@query_cache_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_133_07----------------------#' +SET @@global.query_cache_size = TRUE; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = FALSE; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +'#---------------------FN_DYNVARS_133_08----------------------#' +SET @@global.query_cache_size = 1; +SELECT @@query_cache_size = @@global.query_cache_size; +@@query_cache_size = @@global.query_cache_size +1 +'#---------------------FN_DYNVARS_133_09----------------------#' +SET query_cache_size = 1; +ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_size; +@@query_cache_size +0 +SET local.query_cache_size = 1; +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 'query_cache_size = 1' at line 1 +SELECT local.query_cache_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.query_cache_size = 1; +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 'query_cache_size = 1' at line 1 +SELECT global.query_cache_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT query_cache_size = @@session.query_cache_size; +ERROR 42S22: Unknown column 'query_cache_size' in 'field list' +SET @@global.query_cache_size = @start_value; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 diff --git a/mysql-test/r/query_cache_size_basic_64.result b/mysql-test/r/query_cache_size_basic_64.result new file mode 100644 index 00000000000..0d67eec1ccc --- /dev/null +++ b/mysql-test/r/query_cache_size_basic_64.result @@ -0,0 +1,134 @@ +SET @start_value = @@global.query_cache_size; +SELECT @start_value; +@start_value +0 +'#--------------------FN_DYNVARS_133_01------------------------#' +SET @@global.query_cache_size = 99; +SET @@global.query_cache_size = DEFAULT; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +'#---------------------FN_DYNVARS_133_02-------------------------#' +SET @@global.query_cache_size = @start_value; +SELECT @@global.query_cache_size = 0; +@@global.query_cache_size = 0 +1 +'#--------------------FN_DYNVARS_133_03------------------------#' +SET @@global.query_cache_size = 0; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 1; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 512; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 1024; +Warnings: +Warning 1282 Query cache failed to set size 1024; new query cache size is 0 +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +: 'Bug#34880: Warnings are coming on assinging valid values to variable +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.query_cache_size = 1048576; +SELECT @@global.query_cache_size; +@@global.query_cache_size +1048576 +SET @@global.query_cache_size = 1048575; +SELECT @@global.query_cache_size; +@@global.query_cache_size +1047552 +'#--------------------FN_DYNVARS_133_04-------------------------#' +SET @@global.query_cache_size = -1; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 4294967296; +SELECT @@global.query_cache_size; +@@global.query_cache_size +4294967296 +SET @@global.query_cache_size = 511; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 10000.01; +ERROR 42000: Incorrect argument type to variable 'query_cache_size' +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = -1024; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 42949672950; +Warnings: +Warning 1282 Query cache failed to set size 42949671936; new query cache size is 0 +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.query_cache_size = ON; +ERROR 42000: Incorrect argument type to variable 'query_cache_size' +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'query_cache_size' +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +'#-------------------FN_DYNVARS_133_05----------------------------#' +SET @@session.query_cache_size = 0; +ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_size; +@@query_cache_size +0 +'#----------------------FN_DYNVARS_133_06------------------------#' +SELECT @@global.query_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_cache_size'; +@@global.query_cache_size = VARIABLE_VALUE +1 +SELECT @@query_cache_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_cache_size'; +@@query_cache_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_133_07----------------------#' +SET @@global.query_cache_size = TRUE; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +SET @@global.query_cache_size = FALSE; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 +'#---------------------FN_DYNVARS_133_08----------------------#' +SET @@global.query_cache_size = 1; +SELECT @@query_cache_size = @@global.query_cache_size; +@@query_cache_size = @@global.query_cache_size +1 +'#---------------------FN_DYNVARS_133_09----------------------#' +SET query_cache_size = 1; +ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@query_cache_size; +@@query_cache_size +0 +SET local.query_cache_size = 1; +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 'query_cache_size = 1' at line 1 +SELECT local.query_cache_size; +ERROR 42S02: Unknown table 'local' in field list +SET global.query_cache_size = 1; +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 'query_cache_size = 1' at line 1 +SELECT global.query_cache_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT query_cache_size = @@session.query_cache_size; +ERROR 42S22: Unknown column 'query_cache_size' in 'field list' +SET @@global.query_cache_size = @start_value; +SELECT @@global.query_cache_size; +@@global.query_cache_size +0 diff --git a/mysql-test/r/query_prealloc_size_basic_32.result b/mysql-test/r/query_prealloc_size_basic_32.result new file mode 100644 index 00000000000..176e4fb810a --- /dev/null +++ b/mysql-test/r/query_prealloc_size_basic_32.result @@ -0,0 +1,192 @@ +SET @start_global_value = @@global.query_prealloc_size ; +SELECT @start_global_value; +@start_global_value +8192 +SET @start_session_value = @@session.query_prealloc_size ; +SELECT @start_session_value; +@start_session_value +8192 +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.query_prealloc_size = 100; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '100' +SET @@global.query_prealloc_size = DEFAULT; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@session.query_prealloc_size = 200; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '200' +SET @@session.query_prealloc_size = DEFAULT; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.query_prealloc_size = DEFAULT; +SELECT @@global.query_prealloc_size = 8192; +@@global.query_prealloc_size = 8192 +1 +SET @@session.query_prealloc_size = DEFAULT; +SELECT @@session.query_prealloc_size = 8192; +@@session.query_prealloc_size = 8192 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.query_prealloc_size = 8192; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@global.query_prealloc_size = 4294967295; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +4294966272 +SET @@global.query_prealloc_size = 655354; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +654336 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.query_prealloc_size = 8192; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_size = 4294967295; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +4294966272 +SET @@session.query_prealloc_size = 655345; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +654336 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.query_prealloc_size = 0; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@global.query_prealloc_size = -1024; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@global.query_prealloc_size = 429496729533; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '429496729533' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +4294966272 +SET @@global.query_prealloc_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 +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +4294966272 +SET @@global.query_prealloc_size = test; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +4294966272 +SET @@global.query_prealloc_size = "test"; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +4294966272 +SET @@global.query_prealloc_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +4294966272 +SET @@global.query_prealloc_size = ON; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +4294966272 +SET @@session.query_prealloc_size = 0; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_size = -2; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_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 +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_size = test; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_size = "test"; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.query_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_prealloc_size '; +@@global.query_prealloc_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.query_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_prealloc_size '; +@@session.query_prealloc_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_08-----------------------#' +SET @@global.query_prealloc_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '1' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@global.query_prealloc_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.query_prealloc_size = 10; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '10' +SELECT @@query_prealloc_size = @@global.query_prealloc_size ; +@@query_prealloc_size = @@global.query_prealloc_size +1 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@query_prealloc_size = 100; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '100' +SELECT @@query_prealloc_size = @@local.query_prealloc_size ; +@@query_prealloc_size = @@local.query_prealloc_size +1 +SELECT @@local.query_prealloc_size = @@session.query_prealloc_size ; +@@local.query_prealloc_size = @@session.query_prealloc_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET query_prealloc_size = 1; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '1' +SELECT @@query_prealloc_size ; +@@query_prealloc_size +8192 +SELECT local.query_prealloc_size ; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.query_prealloc_size ; +ERROR 42S02: Unknown table 'session' in field list +SELECT query_prealloc_size = @@session.query_prealloc_size ; +ERROR 42S22: Unknown column 'query_prealloc_size' in 'field list' +SET @@global.query_prealloc_size = @start_global_value; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@session.query_prealloc_size = @start_session_value; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 diff --git a/mysql-test/r/query_prealloc_size_basic_64.result b/mysql-test/r/query_prealloc_size_basic_64.result new file mode 100644 index 00000000000..1c4f5885676 --- /dev/null +++ b/mysql-test/r/query_prealloc_size_basic_64.result @@ -0,0 +1,190 @@ +SET @start_global_value = @@global.query_prealloc_size ; +SELECT @start_global_value; +@start_global_value +8192 +SET @start_session_value = @@session.query_prealloc_size ; +SELECT @start_session_value; +@start_session_value +8192 +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.query_prealloc_size = 100; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '100' +SET @@global.query_prealloc_size = DEFAULT; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@session.query_prealloc_size = 200; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '200' +SET @@session.query_prealloc_size = DEFAULT; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.query_prealloc_size = DEFAULT; +SELECT @@global.query_prealloc_size = 8192; +@@global.query_prealloc_size = 8192 +1 +SET @@session.query_prealloc_size = DEFAULT; +SELECT @@session.query_prealloc_size = 8192; +@@session.query_prealloc_size = 8192 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.query_prealloc_size = 8192; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@global.query_prealloc_size = 4294967295; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +4294966272 +SET @@global.query_prealloc_size = 655354; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +654336 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.query_prealloc_size = 8192; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_size = 4294967295; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +4294966272 +SET @@session.query_prealloc_size = 655345; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +654336 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.query_prealloc_size = 0; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@global.query_prealloc_size = -1024; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@global.query_prealloc_size = 429496729533; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +429496728576 +SET @@global.query_prealloc_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 +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +429496728576 +SET @@global.query_prealloc_size = test; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +429496728576 +SET @@global.query_prealloc_size = "test"; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +429496728576 +SET @@global.query_prealloc_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +429496728576 +SET @@global.query_prealloc_size = ON; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +429496728576 +SET @@session.query_prealloc_size = 0; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_size = -2; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_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 +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_size = test; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +SET @@session.query_prealloc_size = "test"; +ERROR 42000: Incorrect argument type to variable 'query_prealloc_size' +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.query_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='query_prealloc_size '; +@@global.query_prealloc_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.query_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='query_prealloc_size '; +@@session.query_prealloc_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_08-----------------------#' +SET @@global.query_prealloc_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '1' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@global.query_prealloc_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '0' +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.query_prealloc_size = 10; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '10' +SELECT @@query_prealloc_size = @@global.query_prealloc_size ; +@@query_prealloc_size = @@global.query_prealloc_size +1 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@query_prealloc_size = 100; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '100' +SELECT @@query_prealloc_size = @@local.query_prealloc_size ; +@@query_prealloc_size = @@local.query_prealloc_size +1 +SELECT @@local.query_prealloc_size = @@session.query_prealloc_size ; +@@local.query_prealloc_size = @@session.query_prealloc_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET query_prealloc_size = 1; +Warnings: +Warning 1292 Truncated incorrect query_prealloc_size value: '1' +SELECT @@query_prealloc_size ; +@@query_prealloc_size +8192 +SELECT local.query_prealloc_size ; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.query_prealloc_size ; +ERROR 42S02: Unknown table 'session' in field list +SELECT query_prealloc_size = @@session.query_prealloc_size ; +ERROR 42S22: Unknown column 'query_prealloc_size' in 'field list' +SET @@global.query_prealloc_size = @start_global_value; +SELECT @@global.query_prealloc_size ; +@@global.query_prealloc_size +8192 +SET @@session.query_prealloc_size = @start_session_value; +SELECT @@session.query_prealloc_size ; +@@session.query_prealloc_size +8192 diff --git a/mysql-test/r/range_alloc_block_size_basic_32.result b/mysql-test/r/range_alloc_block_size_basic_32.result new file mode 100644 index 00000000000..93441448d90 --- /dev/null +++ b/mysql-test/r/range_alloc_block_size_basic_32.result @@ -0,0 +1,182 @@ +SET @start_global_value = @@global.range_alloc_block_size; +SELECT @start_global_value; +@start_global_value +4096 +SET @start_session_value = @@session.range_alloc_block_size; +SELECT @start_session_value; +@start_session_value +4096 +'#--------------------FN_DYNVARS_137_01-------------------------#' +SET @@global.range_alloc_block_size = 100; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '100' +SET @@global.range_alloc_block_size = DEFAULT; +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@session.range_alloc_block_size = 200; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '200' +SET @@session.range_alloc_block_size = DEFAULT; +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 +'#--------------------FN_DYNVARS_137_02-------------------------#' +SET @@global.range_alloc_block_size = DEFAULT; +SELECT @@global.range_alloc_block_size = 2048; +@@global.range_alloc_block_size = 2048 +0 +SET @@session.range_alloc_block_size = DEFAULT; +SELECT @@session.range_alloc_block_size = 2048; +@@session.range_alloc_block_size = 2048 +0 +'#--------------------FN_DYNVARS_137_03-------------------------#' +SET @@global.range_alloc_block_size = 2048; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '2048' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.range_alloc_block_size = 4294967295; +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4294966272 +SET @@global.range_alloc_block_size = 4294967294; +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4294966272 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_137_04-------------------------#' +SET @@session.range_alloc_block_size = 2048; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '2048' +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 +SET @@session.range_alloc_block_size = 4294967295; +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4294966272 +SET @@session.range_alloc_block_size = 4294967294; +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4294966272 +'#------------------FN_DYNVARS_137_05-----------------------#' +SET @@global.range_alloc_block_size = 0; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@global.range_alloc_block_size = -1024; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@global.range_alloc_block_size = 42949672951; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '42949672951' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4294966272 +SET @@global.range_alloc_block_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 +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4294966272 +SET @@global.range_alloc_block_size = test; +ERROR 42000: Incorrect argument type to variable 'range_alloc_block_size' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4294966272 +SET @@session.range_alloc_block_size = 0; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 +SET @@session.range_alloc_block_size = -2; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 +SET @@session.range_alloc_block_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.range_alloc_block_size = 4294967296; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '4294967296' +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4294966272 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.range_alloc_block_size = test; +ERROR 42000: Incorrect argument type to variable 'range_alloc_block_size' +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4294966272 +'#------------------FN_DYNVARS_137_06-----------------------#' +SELECT @@global.range_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='range_alloc_block_size'; +@@global.range_alloc_block_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_137_07-----------------------#' +SELECT @@session.range_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='range_alloc_block_size'; +@@session.range_alloc_block_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_137_08-----------------------#' +SET @@global.range_alloc_block_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '1' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@global.range_alloc_block_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +'#---------------------FN_DYNVARS_137_09----------------------#' +SET @@global.range_alloc_block_size = 10; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '10' +SELECT @@range_alloc_block_size = @@global.range_alloc_block_size; +@@range_alloc_block_size = @@global.range_alloc_block_size +0 +'#---------------------FN_DYNVARS_137_10----------------------#' +SET @@range_alloc_block_size = 100; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '100' +SELECT @@range_alloc_block_size = @@local.range_alloc_block_size; +@@range_alloc_block_size = @@local.range_alloc_block_size +1 +SELECT @@local.range_alloc_block_size = @@session.range_alloc_block_size; +@@local.range_alloc_block_size = @@session.range_alloc_block_size +1 +'#---------------------FN_DYNVARS_137_11----------------------#' +SET range_alloc_block_size = 1; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '1' +SELECT @@range_alloc_block_size; +@@range_alloc_block_size +4096 +SELECT local.range_alloc_block_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.range_alloc_block_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT range_alloc_block_size = @@session.range_alloc_block_size; +ERROR 42S22: Unknown column 'range_alloc_block_size' in 'field list' +SET @@global.range_alloc_block_size = @start_global_value; +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@session.range_alloc_block_size = @start_session_value; +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 diff --git a/mysql-test/r/range_alloc_block_size_basic_64.result b/mysql-test/r/range_alloc_block_size_basic_64.result new file mode 100644 index 00000000000..26ddfdd2bae --- /dev/null +++ b/mysql-test/r/range_alloc_block_size_basic_64.result @@ -0,0 +1,178 @@ +SET @start_global_value = @@global.range_alloc_block_size; +SELECT @start_global_value; +@start_global_value +4096 +SET @start_session_value = @@session.range_alloc_block_size; +SELECT @start_session_value; +@start_session_value +4096 +'#--------------------FN_DYNVARS_137_01-------------------------#' +SET @@global.range_alloc_block_size = 100; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '100' +SET @@global.range_alloc_block_size = DEFAULT; +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@session.range_alloc_block_size = 200; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '200' +SET @@session.range_alloc_block_size = DEFAULT; +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 +'#--------------------FN_DYNVARS_137_02-------------------------#' +SET @@global.range_alloc_block_size = DEFAULT; +SELECT @@global.range_alloc_block_size = 2048; +@@global.range_alloc_block_size = 2048 +0 +SET @@session.range_alloc_block_size = DEFAULT; +SELECT @@session.range_alloc_block_size = 2048; +@@session.range_alloc_block_size = 2048 +0 +'#--------------------FN_DYNVARS_137_03-------------------------#' +SET @@global.range_alloc_block_size = 2048; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '2048' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.range_alloc_block_size = 4294967295; +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4294966272 +SET @@global.range_alloc_block_size = 4294967294; +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4294966272 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_137_04-------------------------#' +SET @@session.range_alloc_block_size = 2048; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '2048' +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 +SET @@session.range_alloc_block_size = 4294967295; +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4294966272 +SET @@session.range_alloc_block_size = 4294967294; +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4294966272 +'#------------------FN_DYNVARS_137_05-----------------------#' +SET @@global.range_alloc_block_size = 0; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@global.range_alloc_block_size = -1024; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@global.range_alloc_block_size = 42949672951; +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +42949671936 +SET @@global.range_alloc_block_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 +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +42949671936 +SET @@global.range_alloc_block_size = test; +ERROR 42000: Incorrect argument type to variable 'range_alloc_block_size' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +42949671936 +SET @@session.range_alloc_block_size = 0; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 +SET @@session.range_alloc_block_size = -2; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 +SET @@session.range_alloc_block_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.range_alloc_block_size = 4294967296; +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4294967296 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.range_alloc_block_size = test; +ERROR 42000: Incorrect argument type to variable 'range_alloc_block_size' +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4294967296 +'#------------------FN_DYNVARS_137_06-----------------------#' +SELECT @@global.range_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='range_alloc_block_size'; +@@global.range_alloc_block_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_137_07-----------------------#' +SELECT @@session.range_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='range_alloc_block_size'; +@@session.range_alloc_block_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_137_08-----------------------#' +SET @@global.range_alloc_block_size = TRUE; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '1' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@global.range_alloc_block_size = FALSE; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '0' +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +'#---------------------FN_DYNVARS_137_09----------------------#' +SET @@global.range_alloc_block_size = 10; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '10' +SELECT @@range_alloc_block_size = @@global.range_alloc_block_size; +@@range_alloc_block_size = @@global.range_alloc_block_size +0 +'#---------------------FN_DYNVARS_137_10----------------------#' +SET @@range_alloc_block_size = 100; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '100' +SELECT @@range_alloc_block_size = @@local.range_alloc_block_size; +@@range_alloc_block_size = @@local.range_alloc_block_size +1 +SELECT @@local.range_alloc_block_size = @@session.range_alloc_block_size; +@@local.range_alloc_block_size = @@session.range_alloc_block_size +1 +'#---------------------FN_DYNVARS_137_11----------------------#' +SET range_alloc_block_size = 1; +Warnings: +Warning 1292 Truncated incorrect range_alloc_block_size value: '1' +SELECT @@range_alloc_block_size; +@@range_alloc_block_size +4096 +SELECT local.range_alloc_block_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.range_alloc_block_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT range_alloc_block_size = @@session.range_alloc_block_size; +ERROR 42S22: Unknown column 'range_alloc_block_size' in 'field list' +SET @@global.range_alloc_block_size = @start_global_value; +SELECT @@global.range_alloc_block_size; +@@global.range_alloc_block_size +4096 +SET @@session.range_alloc_block_size = @start_session_value; +SELECT @@session.range_alloc_block_size; +@@session.range_alloc_block_size +4096 diff --git a/mysql-test/r/rpl_recovery_rank_basic_32.result b/mysql-test/r/rpl_recovery_rank_basic_32.result new file mode 100644 index 00000000000..d4dd46eba71 --- /dev/null +++ b/mysql-test/r/rpl_recovery_rank_basic_32.result @@ -0,0 +1,110 @@ +SET @start_global_value = @@global.rpl_recovery_rank; +SELECT @start_global_value; +@start_global_value +0 +'#--------------------FN_DYNVARS_142_01-------------------------#' +SET @@global.rpl_recovery_rank = 500000; +SET @@global.rpl_recovery_rank = DEFAULT; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +'#--------------------FN_DYNVARS_142_02-------------------------#' +SET @@global.rpl_recovery_rank = 0; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +SET @@global.rpl_recovery_rank = 1024; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +1024 +SET @@global.rpl_recovery_rank = 123456789; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +123456789 +SET @@global.rpl_recovery_rank = 2147483648*2; +Warnings: +Warning 1292 Truncated incorrect rpl-recovery-rank value: '4294967296' +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +4294967295 +SET @@global.rpl_recovery_rank = 2147483648*1024; +Warnings: +Warning 1292 Truncated incorrect rpl-recovery-rank value: '2199023255552' +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +4294967295 +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +4294967295 +SET @@global.rpl_recovery_rank = 2147483648*2147483648; +Warnings: +Warning 1292 Truncated incorrect rpl-recovery-rank value: '4611686018427387904' +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +4294967295 +'#--------------------FN_DYNVARS_142_03-------------------------#' +SET @@rpl_recovery_rank = 2; +ERROR HY000: Variable 'rpl_recovery_rank' is a GLOBAL variable and should be set with SET GLOBAL +SET @@session.rpl_recovery_rank = 3; +ERROR HY000: Variable 'rpl_recovery_rank' is a GLOBAL variable and should be set with SET GLOBAL +SET @@local.rpl_recovery_rank = 4; +ERROR HY000: Variable 'rpl_recovery_rank' is a GLOBAL variable and should be set with SET GLOBAL +'#------------------FN_DYNVARS_142_04-----------------------#' +SET @@global.rpl_recovery_rank = -1; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +SET @@global.rpl_recovery_rank = -2147483648; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +SET @@global.rpl_recovery_rank = -2147483649; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +SET @@global.rpl_recovery_rank = 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 @@global.rpl_recovery_rank = 2147483649.56; +ERROR 42000: Incorrect argument type to variable 'rpl_recovery_rank' +SET @@global.rpl_recovery_rank = 1G; +ERROR 42000: Incorrect argument type to variable 'rpl_recovery_rank' +'#------------------FN_DYNVARS_142_05-----------------------#' +SET @@global.rpl_recovery_rank = 3000; +SELECT @@global.rpl_recovery_rank = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='rpl_recovery_rank'; +@@global.rpl_recovery_rank = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_142_06-----------------------#' +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='rpl_recovery_rank'; +count(VARIABLE_VALUE) +1 +'#------------------FN_DYNVARS_142_07-----------------------#' +SET @@global.rpl_recovery_rank = TRUE; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +1 +SET @@global.rpl_recovery_rank = FALSE; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +'#---------------------FN_DYNVARS_001_08----------------------#' +SET @@global.rpl_recovery_rank = 512; +SELECT @@rpl_recovery_rank = @@global.rpl_recovery_rank; +@@rpl_recovery_rank = @@global.rpl_recovery_rank +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET rpl_recovery_rank = 2048; +ERROR HY000: Variable 'rpl_recovery_rank' is a GLOBAL variable and should be set with SET GLOBAL +SELECT rpl_recovery_rank; +ERROR 42S22: Unknown column 'rpl_recovery_rank' in 'field list' +SELECT @@rpl_recovery_rank; +@@rpl_recovery_rank +512 +SET global rpl_recovery_rank = 64; +SET @@global.rpl_recovery_rank = @start_global_value; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 diff --git a/mysql-test/r/rpl_recovery_rank_basic_64.result b/mysql-test/r/rpl_recovery_rank_basic_64.result new file mode 100644 index 00000000000..d4dd46eba71 --- /dev/null +++ b/mysql-test/r/rpl_recovery_rank_basic_64.result @@ -0,0 +1,110 @@ +SET @start_global_value = @@global.rpl_recovery_rank; +SELECT @start_global_value; +@start_global_value +0 +'#--------------------FN_DYNVARS_142_01-------------------------#' +SET @@global.rpl_recovery_rank = 500000; +SET @@global.rpl_recovery_rank = DEFAULT; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +'#--------------------FN_DYNVARS_142_02-------------------------#' +SET @@global.rpl_recovery_rank = 0; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +SET @@global.rpl_recovery_rank = 1024; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +1024 +SET @@global.rpl_recovery_rank = 123456789; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +123456789 +SET @@global.rpl_recovery_rank = 2147483648*2; +Warnings: +Warning 1292 Truncated incorrect rpl-recovery-rank value: '4294967296' +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +4294967295 +SET @@global.rpl_recovery_rank = 2147483648*1024; +Warnings: +Warning 1292 Truncated incorrect rpl-recovery-rank value: '2199023255552' +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +4294967295 +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +4294967295 +SET @@global.rpl_recovery_rank = 2147483648*2147483648; +Warnings: +Warning 1292 Truncated incorrect rpl-recovery-rank value: '4611686018427387904' +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +4294967295 +'#--------------------FN_DYNVARS_142_03-------------------------#' +SET @@rpl_recovery_rank = 2; +ERROR HY000: Variable 'rpl_recovery_rank' is a GLOBAL variable and should be set with SET GLOBAL +SET @@session.rpl_recovery_rank = 3; +ERROR HY000: Variable 'rpl_recovery_rank' is a GLOBAL variable and should be set with SET GLOBAL +SET @@local.rpl_recovery_rank = 4; +ERROR HY000: Variable 'rpl_recovery_rank' is a GLOBAL variable and should be set with SET GLOBAL +'#------------------FN_DYNVARS_142_04-----------------------#' +SET @@global.rpl_recovery_rank = -1; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +SET @@global.rpl_recovery_rank = -2147483648; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +SET @@global.rpl_recovery_rank = -2147483649; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +SET @@global.rpl_recovery_rank = 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 @@global.rpl_recovery_rank = 2147483649.56; +ERROR 42000: Incorrect argument type to variable 'rpl_recovery_rank' +SET @@global.rpl_recovery_rank = 1G; +ERROR 42000: Incorrect argument type to variable 'rpl_recovery_rank' +'#------------------FN_DYNVARS_142_05-----------------------#' +SET @@global.rpl_recovery_rank = 3000; +SELECT @@global.rpl_recovery_rank = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='rpl_recovery_rank'; +@@global.rpl_recovery_rank = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_142_06-----------------------#' +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='rpl_recovery_rank'; +count(VARIABLE_VALUE) +1 +'#------------------FN_DYNVARS_142_07-----------------------#' +SET @@global.rpl_recovery_rank = TRUE; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +1 +SET @@global.rpl_recovery_rank = FALSE; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 +'#---------------------FN_DYNVARS_001_08----------------------#' +SET @@global.rpl_recovery_rank = 512; +SELECT @@rpl_recovery_rank = @@global.rpl_recovery_rank; +@@rpl_recovery_rank = @@global.rpl_recovery_rank +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET rpl_recovery_rank = 2048; +ERROR HY000: Variable 'rpl_recovery_rank' is a GLOBAL variable and should be set with SET GLOBAL +SELECT rpl_recovery_rank; +ERROR 42S22: Unknown column 'rpl_recovery_rank' in 'field list' +SELECT @@rpl_recovery_rank; +@@rpl_recovery_rank +512 +SET global rpl_recovery_rank = 64; +SET @@global.rpl_recovery_rank = @start_global_value; +SELECT @@global.rpl_recovery_rank; +@@global.rpl_recovery_rank +0 diff --git a/mysql-test/r/server_id_basic_32.result b/mysql-test/r/server_id_basic_32.result new file mode 100644 index 00000000000..6f801fc627b --- /dev/null +++ b/mysql-test/r/server_id_basic_32.result @@ -0,0 +1,117 @@ +SET @@global.general_log= 0; +SET @start_global_value = @@global.server_id; +SELECT @start_global_value; +@start_global_value +1 +'#--------------------FN_DYNVARS_144_01-------------------------#' +SET @@global.server_id = 500000; +SET @@global.server_id = DEFAULT; +SELECT @@global.server_id; +@@global.server_id +0 +'#--------------------FN_DYNVARS_144_02-------------------------#' +SET @@global.server_id = DEFAULT; +SELECT @@global.server_id = 0; +@@global.server_id = 0 +1 +'#--------------------FN_DYNVARS_144_03-------------------------#' +SET @@global.server_id = 0; +SELECT @@global.server_id; +@@global.server_id +0 +SET @@global.server_id = 1; +SELECT @@global.server_id; +@@global.server_id +1 +SET @@global.server_id = 15; +SELECT @@global.server_id; +@@global.server_id +15 +SET @@global.server_id = 1024; +SELECT @@global.server_id; +@@global.server_id +1024 +SET @@global.server_id = 123456789; +SELECT @@global.server_id; +@@global.server_id +123456789 +SET @@global.server_id = 2147483648; +SELECT @@global.server_id; +@@global.server_id +2147483648 +SET @@global.server_id = 2147483648*2-1; +SELECT @@global.server_id; +@@global.server_id +4294967295 +'#--------------------FN_DYNVARS_144_04-------------------------#' +SET @@server_id = 2; +ERROR HY000: Variable 'server_id' is a GLOBAL variable and should be set with SET GLOBAL +SET @@session.server_id = 3; +ERROR HY000: Variable 'server_id' is a GLOBAL variable and should be set with SET GLOBAL +SET @@local.server_id = 4; +ERROR HY000: Variable 'server_id' is a GLOBAL variable and should be set with SET GLOBAL +'#------------------FN_DYNVARS_144_05-----------------------#' +SET @@global.server_id = -1; +SELECT @@global.server_id; +@@global.server_id +0 +SET @@global.server_id = -2147483648; +SELECT @@global.server_id; +@@global.server_id +0 +SET @@global.server_id = 2147483649*2; +Warnings: +Warning 1292 Truncated incorrect server-id value: '4294967298' +SELECT @@global.server_id; +@@global.server_id +4294967295 +SET @@global.server_id = 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 @@global.server_id = '125'; +ERROR 42000: Incorrect argument type to variable 'server_id' +SET @@global.server_id = 7483649.56; +ERROR 42000: Incorrect argument type to variable 'server_id' +SET @@global.server_id = 1G; +ERROR 42000: Incorrect argument type to variable 'server_id' +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#------------------FN_DYNVARS_144_06-----------------------#' +SET @@global.server_id = 3000; +SELECT @@global.server_id = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='server_id'; +@@global.server_id = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_144_07-----------------------#' +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='server_id'; +count(VARIABLE_VALUE) +1 +'#------------------FN_DYNVARS_144_08-----------------------#' +SET @@global.server_id = TRUE; +SELECT @@global.server_id; +@@global.server_id +1 +SET @@global.server_id = FALSE; +SELECT @@global.server_id; +@@global.server_id +0 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.server_id = 512; +SELECT @@server_id = @@global.server_id; +@@server_id = @@global.server_id +1 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET server_id = 2048; +ERROR HY000: Variable 'server_id' is a GLOBAL variable and should be set with SET GLOBAL +SELECT server_id; +ERROR 42S22: Unknown column 'server_id' in 'field list' +SELECT @@server_id; +@@server_id +512 +SET global server_id = 99; +SET @@global.server_id = @start_global_value; +SELECT @@global.server_id; +@@global.server_id +1 +SET @@global.general_log= 1; diff --git a/mysql-test/r/server_id_basic_64.result b/mysql-test/r/server_id_basic_64.result new file mode 100644 index 00000000000..b6f3095ccfe --- /dev/null +++ b/mysql-test/r/server_id_basic_64.result @@ -0,0 +1,115 @@ +SET @@global.general_log= 0; +SET @start_global_value = @@global.server_id; +SELECT @start_global_value; +@start_global_value +1 +'#--------------------FN_DYNVARS_144_01-------------------------#' +SET @@global.server_id = 500000; +SET @@global.server_id = DEFAULT; +SELECT @@global.server_id; +@@global.server_id +0 +'#--------------------FN_DYNVARS_144_02-------------------------#' +SET @@global.server_id = DEFAULT; +SELECT @@global.server_id = 0; +@@global.server_id = 0 +1 +'#--------------------FN_DYNVARS_144_03-------------------------#' +SET @@global.server_id = 0; +SELECT @@global.server_id; +@@global.server_id +0 +SET @@global.server_id = 1; +SELECT @@global.server_id; +@@global.server_id +1 +SET @@global.server_id = 15; +SELECT @@global.server_id; +@@global.server_id +15 +SET @@global.server_id = 1024; +SELECT @@global.server_id; +@@global.server_id +1024 +SET @@global.server_id = 123456789; +SELECT @@global.server_id; +@@global.server_id +123456789 +SET @@global.server_id = 2147483648; +SELECT @@global.server_id; +@@global.server_id +2147483648 +SET @@global.server_id = 2147483648*2-1; +SELECT @@global.server_id; +@@global.server_id +4294967295 +'#--------------------FN_DYNVARS_144_04-------------------------#' +SET @@server_id = 2; +ERROR HY000: Variable 'server_id' is a GLOBAL variable and should be set with SET GLOBAL +SET @@session.server_id = 3; +ERROR HY000: Variable 'server_id' is a GLOBAL variable and should be set with SET GLOBAL +SET @@local.server_id = 4; +ERROR HY000: Variable 'server_id' is a GLOBAL variable and should be set with SET GLOBAL +'#------------------FN_DYNVARS_144_05-----------------------#' +SET @@global.server_id = -1; +SELECT @@global.server_id; +@@global.server_id +0 +SET @@global.server_id = -2147483648; +SELECT @@global.server_id; +@@global.server_id +0 +SET @@global.server_id = 2147483649*2; +SELECT @@global.server_id; +@@global.server_id +4294967298 +SET @@global.server_id = 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 @@global.server_id = '125'; +ERROR 42000: Incorrect argument type to variable 'server_id' +SET @@global.server_id = 7483649.56; +ERROR 42000: Incorrect argument type to variable 'server_id' +SET @@global.server_id = 1G; +ERROR 42000: Incorrect argument type to variable 'server_id' +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#------------------FN_DYNVARS_144_06-----------------------#' +SET @@global.server_id = 3000; +SELECT @@global.server_id = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='server_id'; +@@global.server_id = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_144_07-----------------------#' +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='server_id'; +count(VARIABLE_VALUE) +1 +'#------------------FN_DYNVARS_144_08-----------------------#' +SET @@global.server_id = TRUE; +SELECT @@global.server_id; +@@global.server_id +1 +SET @@global.server_id = FALSE; +SELECT @@global.server_id; +@@global.server_id +0 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.server_id = 512; +SELECT @@server_id = @@global.server_id; +@@server_id = @@global.server_id +1 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET server_id = 2048; +ERROR HY000: Variable 'server_id' is a GLOBAL variable and should be set with SET GLOBAL +SELECT server_id; +ERROR 42S22: Unknown column 'server_id' in 'field list' +SELECT @@server_id; +@@server_id +512 +SET global server_id = 99; +SET @@global.server_id = @start_global_value; +SELECT @@global.server_id; +@@global.server_id +1 +SET @@global.general_log= 1; diff --git a/mysql-test/r/slave_transaction_retries_basic_32.result b/mysql-test/r/slave_transaction_retries_basic_32.result new file mode 100644 index 00000000000..5b77c500aa0 --- /dev/null +++ b/mysql-test/r/slave_transaction_retries_basic_32.result @@ -0,0 +1,119 @@ +SET @start_global_value = @@global.slave_transaction_retries; +SELECT @start_global_value; +@start_global_value +10 +'#--------------------FN_DYNVARS_149_01-------------------------#' +SET @@global.slave_transaction_retries = 50; +SET @@global.slave_transaction_retries = DEFAULT; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +10 +'#--------------------FN_DYNVARS_149_02-------------------------#' +SET @@global.slave_transaction_retries = DEFAULT; +SELECT @@global.slave_transaction_retries = 10; +@@global.slave_transaction_retries = 10 +1 +'#--------------------FN_DYNVARS_149_03-------------------------#' +SET @@global.slave_transaction_retries = 0; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +0 +SET @@global.slave_transaction_retries = 1; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +1 +SET @@global.slave_transaction_retries = 15; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +15 +SET @@global.slave_transaction_retries = 1024; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +1024 +SET @@global.slave_transaction_retries = 2147483648; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +2147483648 +SET @@global.slave_transaction_retries = 2147483648*2-1; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +4294967295 +SET @@global.slave_transaction_retries = 2147483649*2; +Warnings: +Warning 1292 Truncated incorrect slave_transaction_retries value: '4294967298' +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +4294967295 +SET @@global.slave_transaction_retries = 4294967295; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +4294967295 +'#--------------------FN_DYNVARS_149_04-------------------------#' +SET @@slave_transaction_retries = 2; +ERROR HY000: Variable 'slave_transaction_retries' is a GLOBAL variable and should be set with SET GLOBAL +SET @@session.slave_transaction_retries = 3; +ERROR HY000: Variable 'slave_transaction_retries' is a GLOBAL variable and should be set with SET GLOBAL +SET @@local.slave_transaction_retries = 4; +ERROR HY000: Variable 'slave_transaction_retries' is a GLOBAL variable and should be set with SET GLOBAL +'#------------------FN_DYNVARS_149_05-----------------------#' +SET @@global.slave_transaction_retries = -1; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +0 +SET @@global.slave_transaction_retries = 2147483649*2147483649; +Warnings: +Warning 1292 Truncated incorrect slave_transaction_retries value: '4611686022722355201' +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +4294967295 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.slave_transaction_retries = 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 @@global.slave_transaction_retries = '100'; +ERROR 42000: Incorrect argument type to variable 'slave_transaction_retries' +SET @@global.slave_transaction_retries = 7483649.56; +ERROR 42000: Incorrect argument type to variable 'slave_transaction_retries' +SET @@global.slave_transaction_retries = ON; +ERROR 42000: Incorrect argument type to variable 'slave_transaction_retries' +SET @@global.slave_transaction_retries = OFF; +ERROR 42000: Incorrect argument type to variable 'slave_transaction_retries' +'#------------------FN_DYNVARS_149_06-----------------------#' +SET @@global.slave_transaction_retries = 3000; +SELECT @@global.slave_transaction_retries = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='slave_transaction_retries'; +@@global.slave_transaction_retries = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_149_07-----------------------#' +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='slave_transaction_retries'; +count(VARIABLE_VALUE) +1 +'#------------------FN_DYNVARS_149_08-----------------------#' +SET @@global.slave_transaction_retries = TRUE; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +1 +SET @@global.slave_transaction_retries = FALSE; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +0 +'#---------------------FN_DYNVARS_149_09----------------------#' +SET @@global.slave_transaction_retries = 60*60; +SELECT @@slave_transaction_retries = @@global.slave_transaction_retries; +@@slave_transaction_retries = @@global.slave_transaction_retries +1 +'#---------------------FN_DYNVARS_149_10----------------------#' +SET slave_transaction_retries = 2048; +ERROR HY000: Variable 'slave_transaction_retries' is a GLOBAL variable and should be set with SET GLOBAL +SELECT slave_transaction_retries; +ERROR 42S22: Unknown column 'slave_transaction_retries' in 'field list' +SELECT @@slave_transaction_retries; +@@slave_transaction_retries +3600 +SET global slave_transaction_retries = 99; +SET @@global.slave_transaction_retries = @start_global_value; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +10 diff --git a/mysql-test/r/slave_transaction_retries_basic_64.result b/mysql-test/r/slave_transaction_retries_basic_64.result new file mode 100644 index 00000000000..9434b14b238 --- /dev/null +++ b/mysql-test/r/slave_transaction_retries_basic_64.result @@ -0,0 +1,115 @@ +SET @start_global_value = @@global.slave_transaction_retries; +SELECT @start_global_value; +@start_global_value +10 +'#--------------------FN_DYNVARS_149_01-------------------------#' +SET @@global.slave_transaction_retries = 50; +SET @@global.slave_transaction_retries = DEFAULT; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +10 +'#--------------------FN_DYNVARS_149_02-------------------------#' +SET @@global.slave_transaction_retries = DEFAULT; +SELECT @@global.slave_transaction_retries = 10; +@@global.slave_transaction_retries = 10 +1 +'#--------------------FN_DYNVARS_149_03-------------------------#' +SET @@global.slave_transaction_retries = 0; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +0 +SET @@global.slave_transaction_retries = 1; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +1 +SET @@global.slave_transaction_retries = 15; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +15 +SET @@global.slave_transaction_retries = 1024; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +1024 +SET @@global.slave_transaction_retries = 2147483648; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +2147483648 +SET @@global.slave_transaction_retries = 2147483648*2-1; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +4294967295 +SET @@global.slave_transaction_retries = 2147483649*2; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +4294967298 +SET @@global.slave_transaction_retries = 4294967295; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +4294967295 +'#--------------------FN_DYNVARS_149_04-------------------------#' +SET @@slave_transaction_retries = 2; +ERROR HY000: Variable 'slave_transaction_retries' is a GLOBAL variable and should be set with SET GLOBAL +SET @@session.slave_transaction_retries = 3; +ERROR HY000: Variable 'slave_transaction_retries' is a GLOBAL variable and should be set with SET GLOBAL +SET @@local.slave_transaction_retries = 4; +ERROR HY000: Variable 'slave_transaction_retries' is a GLOBAL variable and should be set with SET GLOBAL +'#------------------FN_DYNVARS_149_05-----------------------#' +SET @@global.slave_transaction_retries = -1; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +0 +SET @@global.slave_transaction_retries = 2147483649*2147483649; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +4611686022722355201 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +SET @@global.slave_transaction_retries = 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 @@global.slave_transaction_retries = '100'; +ERROR 42000: Incorrect argument type to variable 'slave_transaction_retries' +SET @@global.slave_transaction_retries = 7483649.56; +ERROR 42000: Incorrect argument type to variable 'slave_transaction_retries' +SET @@global.slave_transaction_retries = ON; +ERROR 42000: Incorrect argument type to variable 'slave_transaction_retries' +SET @@global.slave_transaction_retries = OFF; +ERROR 42000: Incorrect argument type to variable 'slave_transaction_retries' +'#------------------FN_DYNVARS_149_06-----------------------#' +SET @@global.slave_transaction_retries = 3000; +SELECT @@global.slave_transaction_retries = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='slave_transaction_retries'; +@@global.slave_transaction_retries = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_149_07-----------------------#' +SELECT count(VARIABLE_VALUE) +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='slave_transaction_retries'; +count(VARIABLE_VALUE) +1 +'#------------------FN_DYNVARS_149_08-----------------------#' +SET @@global.slave_transaction_retries = TRUE; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +1 +SET @@global.slave_transaction_retries = FALSE; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +0 +'#---------------------FN_DYNVARS_149_09----------------------#' +SET @@global.slave_transaction_retries = 60*60; +SELECT @@slave_transaction_retries = @@global.slave_transaction_retries; +@@slave_transaction_retries = @@global.slave_transaction_retries +1 +'#---------------------FN_DYNVARS_149_10----------------------#' +SET slave_transaction_retries = 2048; +ERROR HY000: Variable 'slave_transaction_retries' is a GLOBAL variable and should be set with SET GLOBAL +SELECT slave_transaction_retries; +ERROR 42S22: Unknown column 'slave_transaction_retries' in 'field list' +SELECT @@slave_transaction_retries; +@@slave_transaction_retries +3600 +SET global slave_transaction_retries = 99; +SET @@global.slave_transaction_retries = @start_global_value; +SELECT @@global.slave_transaction_retries; +@@global.slave_transaction_retries +10 diff --git a/mysql-test/r/sort_buffer_size_basic_32.result b/mysql-test/r/sort_buffer_size_basic_32.result new file mode 100644 index 00000000000..09a1fe59046 --- /dev/null +++ b/mysql-test/r/sort_buffer_size_basic_32.result @@ -0,0 +1,193 @@ +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 +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 +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 +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 +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 +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 +1 +SET @@global.sort_buffer_size = 4294967295; +SELECT @@global.sort_buffer_size; +@@global.sort_buffer_size +4294967295 +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 +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 +1 +SET @@session.sort_buffer_size = 4294967295; +SELECT @@session.sort_buffer_size; +@@session.sort_buffer_size +4294967295 +SET @@session.sort_buffer_size = 4294967294; +SELECT @@session.sort_buffer_size; +@@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 +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 +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 +SET @@global.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 +SELECT @@global.sort_buffer_size; +@@global.sort_buffer_size +4294967295 +SET @@global.sort_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'sort_buffer_size' +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 +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 +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'; +@@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'; +@@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 +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 +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 +SELECT @@local.sort_buffer_size = @@session.sort_buffer_size; +@@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 local.sort_buffer_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.sort_buffer_size; +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 diff --git a/mysql-test/r/sort_buffer_size_basic_64.result b/mysql-test/r/sort_buffer_size_basic_64.result new file mode 100644 index 00000000000..e9bd14abc67 --- /dev/null +++ b/mysql-test/r/sort_buffer_size_basic_64.result @@ -0,0 +1,189 @@ +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 +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 +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 +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 +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 +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 +1 +SET @@global.sort_buffer_size = 4294967295; +SELECT @@global.sort_buffer_size; +@@global.sort_buffer_size +4294967295 +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 +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 +1 +SET @@session.sort_buffer_size = 4294967295; +SELECT @@session.sort_buffer_size; +@@session.sort_buffer_size +4294967295 +SET @@session.sort_buffer_size = 4294967294; +SELECT @@session.sort_buffer_size; +@@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 +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 +1 +SET @@global.sort_buffer_size = 4294967296; +SELECT @@global.sort_buffer_size; +@@global.sort_buffer_size +4294967296 +SET @@global.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 +SELECT @@global.sort_buffer_size; +@@global.sort_buffer_size +4294967296 +SET @@global.sort_buffer_size = test; +ERROR 42000: Incorrect argument type to variable 'sort_buffer_size' +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 +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 +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; +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'; +@@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'; +@@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 +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 +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 +SELECT @@local.sort_buffer_size = @@session.sort_buffer_size; +@@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 local.sort_buffer_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.sort_buffer_size; +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 diff --git a/mysql-test/r/sync_binlog_basic_32.result b/mysql-test/r/sync_binlog_basic_32.result new file mode 100644 index 00000000000..3d9bfb6d218 --- /dev/null +++ b/mysql-test/r/sync_binlog_basic_32.result @@ -0,0 +1,105 @@ +SET @start_value = @@global.sync_binlog; +SELECT @start_value; +@start_value +0 +'#--------------------FN_DYNVARS_168_01------------------------#' +SET @@global.sync_binlog = 99; +SET @@global.sync_binlog = DEFAULT; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 +'#---------------------FN_DYNVARS_168_02-------------------------#' +SET @@global.sync_binlog = @start_value; +SELECT @@global.sync_binlog = 0; +@@global.sync_binlog = 0 +1 +'#--------------------FN_DYNVARS_168_03------------------------#' +SET @@global.sync_binlog = 0; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 +SET @@global.sync_binlog = 1; +SELECT @@global.sync_binlog; +@@global.sync_binlog +1 +SET @@global.sync_binlog = 4294967295; +SELECT @@global.sync_binlog; +@@global.sync_binlog +4294967295 +SET @@global.sync_binlog = 4294967294; +SELECT @@global.sync_binlog; +@@global.sync_binlog +4294967294 +SET @@global.sync_binlog = 65536; +SELECT @@global.sync_binlog; +@@global.sync_binlog +65536 +'#--------------------FN_DYNVARS_168_04-------------------------#' +SET @@global.sync_binlog = -1; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 +SET @@global.sync_binlog = 4294967296; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 +SET @@global.sync_binlog = 10240022115; +SELECT @@global.sync_binlog; +@@global.sync_binlog +1650087523 +SET @@global.sync_binlog = 10000.01; +ERROR 42000: Incorrect argument type to variable 'sync_binlog' +SELECT @@global.sync_binlog; +@@global.sync_binlog +1650087523 +SET @@global.sync_binlog = -1024; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 +SET @@global.sync_binlog = 42949672950; +SELECT @@global.sync_binlog; +@@global.sync_binlog +4294967286 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.sync_binlog = ON; +ERROR 42000: Incorrect argument type to variable 'sync_binlog' +SELECT @@global.sync_binlog; +@@global.sync_binlog +4294967286 +SET @@global.sync_binlog = 'test'; +ERROR 42000: Incorrect argument type to variable 'sync_binlog' +SELECT @@global.sync_binlog; +@@global.sync_binlog +4294967286 +'#-------------------FN_DYNVARS_168_05----------------------------#' +SET @@session.sync_binlog = 0; +ERROR HY000: Variable 'sync_binlog' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@sync_binlog; +@@sync_binlog +4294967286 +'#----------------------FN_DYNVARS_168_06------------------------#' +SELECT @@global.sync_binlog = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='sync_binlog'; +@@global.sync_binlog = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_168_07----------------------#' +SET sync_binlog = 1; +ERROR HY000: Variable 'sync_binlog' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@sync_binlog; +@@sync_binlog +4294967286 +SET local.sync_binlog = 1; +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 'sync_binlog = 1' at line 1 +SELECT local.sync_binlog; +ERROR 42S02: Unknown table 'local' in field list +SET global.sync_binlog = 1; +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 'sync_binlog = 1' at line 1 +SELECT global.sync_binlog; +ERROR 42S02: Unknown table 'global' in field list +SELECT sync_binlog = @@session.sync_binlog; +ERROR 42S22: Unknown column 'sync_binlog' in 'field list' +SET @@global.sync_binlog = @start_value; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 diff --git a/mysql-test/r/sync_binlog_basic_64.result b/mysql-test/r/sync_binlog_basic_64.result new file mode 100644 index 00000000000..ffd1b3fc4f1 --- /dev/null +++ b/mysql-test/r/sync_binlog_basic_64.result @@ -0,0 +1,105 @@ +SET @start_value = @@global.sync_binlog; +SELECT @start_value; +@start_value +0 +'#--------------------FN_DYNVARS_168_01------------------------#' +SET @@global.sync_binlog = 99; +SET @@global.sync_binlog = DEFAULT; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 +'#---------------------FN_DYNVARS_168_02-------------------------#' +SET @@global.sync_binlog = @start_value; +SELECT @@global.sync_binlog = 0; +@@global.sync_binlog = 0 +1 +'#--------------------FN_DYNVARS_168_03------------------------#' +SET @@global.sync_binlog = 0; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 +SET @@global.sync_binlog = 1; +SELECT @@global.sync_binlog; +@@global.sync_binlog +1 +SET @@global.sync_binlog = 4294967295; +SELECT @@global.sync_binlog; +@@global.sync_binlog +4294967295 +SET @@global.sync_binlog = 4294967294; +SELECT @@global.sync_binlog; +@@global.sync_binlog +4294967294 +SET @@global.sync_binlog = 65536; +SELECT @@global.sync_binlog; +@@global.sync_binlog +65536 +'#--------------------FN_DYNVARS_168_04-------------------------#' +SET @@global.sync_binlog = -1; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 +SET @@global.sync_binlog = 4294967296; +SELECT @@global.sync_binlog; +@@global.sync_binlog +4294967296 +SET @@global.sync_binlog = 10240022115; +SELECT @@global.sync_binlog; +@@global.sync_binlog +10240022115 +SET @@global.sync_binlog = 10000.01; +ERROR 42000: Incorrect argument type to variable 'sync_binlog' +SELECT @@global.sync_binlog; +@@global.sync_binlog +10240022115 +SET @@global.sync_binlog = -1024; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 +SET @@global.sync_binlog = 42949672950; +SELECT @@global.sync_binlog; +@@global.sync_binlog +42949672950 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.sync_binlog = ON; +ERROR 42000: Incorrect argument type to variable 'sync_binlog' +SELECT @@global.sync_binlog; +@@global.sync_binlog +42949672950 +SET @@global.sync_binlog = 'test'; +ERROR 42000: Incorrect argument type to variable 'sync_binlog' +SELECT @@global.sync_binlog; +@@global.sync_binlog +42949672950 +'#-------------------FN_DYNVARS_168_05----------------------------#' +SET @@session.sync_binlog = 0; +ERROR HY000: Variable 'sync_binlog' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@sync_binlog; +@@sync_binlog +42949672950 +'#----------------------FN_DYNVARS_168_06------------------------#' +SELECT @@global.sync_binlog = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='sync_binlog'; +@@global.sync_binlog = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_168_07----------------------#' +SET sync_binlog = 1; +ERROR HY000: Variable 'sync_binlog' is a GLOBAL variable and should be set with SET GLOBAL +SELECT @@sync_binlog; +@@sync_binlog +42949672950 +SET local.sync_binlog = 1; +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 'sync_binlog = 1' at line 1 +SELECT local.sync_binlog; +ERROR 42S02: Unknown table 'local' in field list +SET global.sync_binlog = 1; +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 'sync_binlog = 1' at line 1 +SELECT global.sync_binlog; +ERROR 42S02: Unknown table 'global' in field list +SELECT sync_binlog = @@session.sync_binlog; +ERROR 42S22: Unknown column 'sync_binlog' in 'field list' +SET @@global.sync_binlog = @start_value; +SELECT @@global.sync_binlog; +@@global.sync_binlog +0 diff --git a/mysql-test/r/timestamp_basic_32.result b/mysql-test/r/timestamp_basic_32.result new file mode 100644 index 00000000000..cc4f0324c0f --- /dev/null +++ b/mysql-test/r/timestamp_basic_32.result @@ -0,0 +1,73 @@ +SET @session_start_value = @@session.timestamp; +'#--------------------FN_DYNVARS_001_01------------------------#' +SET @@timestamp = DEFAULT; +'timestamp does not have any DEFAULT value' +'#---------------------FN_DYNVARS_001_02-------------------------#' +SET @@global.timestamp = "1000"; +ERROR HY000: Variable 'timestamp' is a SESSION variable and can't be used with SET GLOBAL +'#--------------------FN_DYNVARS_001_03------------------------#' +SET @@timestamp = 0; +'Setting 0 resets timestamp to session default timestamp' +SET @@timestamp = 123456789123456; +SELECT @@timestamp; +@@timestamp +2249167232 +SET @@timestamp = 60*60*60*60*365; +SELECT @@timestamp; +@@timestamp +435432704 +SET @@timestamp = -1000000000; +SELECT @@timestamp; +@@timestamp +3294967296 +SET @temp_ts = @@timestamp - @@timestamp; +SELECT @temp_ts; +@temp_ts +0 +'#--------------------FN_DYNVARS_001_04-------------------------#' +SET @@timestamp = "100"; +ERROR 42000: Incorrect argument type to variable 'timestamp' +'Bug# 34836: Documentation says its a string variable but infact its numeric' +SET @@timestamp = " "; +ERROR 42000: Incorrect argument type to variable 'timestamp' +SET @@timestamp = 1.1; +ERROR 42000: Incorrect argument type to variable 'timestamp' +SET @@timestamp = 9999999999999999999999; +ERROR 42000: Incorrect argument type to variable 'timestamp' +'#----------------------FN_DYNVARS_001_06------------------------#' +SELECT @@timestamp = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='timestamp'; +@@timestamp = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_08-------------------------#' +SET @@timestamp = OFF; +ERROR 42000: Incorrect argument type to variable 'timestamp' +SET @@timestamp = ON; +ERROR 42000: Incorrect argument type to variable 'timestamp' +SET @@timestamp = TRUE; +SELECT @@timestamp; +@@timestamp +1 +SET @@timestamp = FALSE; +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@timestamp = 123456; +SELECT @@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp; +@@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp +1 +SET @@timestamp = 654321; +SELECT @@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp; +@@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET timestamp = 1; +SELECT @@timestamp; +@@timestamp +1 +SELECT local.timestamp; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.timestamp; +ERROR 42S02: Unknown table 'session' in field list +SELECT timestamp = @@session.timestamp; +ERROR 42S22: Unknown column 'timestamp' in 'field list' +SET @@timestamp = @session_start_value; diff --git a/mysql-test/r/timestamp_basic_64.result b/mysql-test/r/timestamp_basic_64.result new file mode 100644 index 00000000000..df877cd455b --- /dev/null +++ b/mysql-test/r/timestamp_basic_64.result @@ -0,0 +1,73 @@ +SET @session_start_value = @@session.timestamp; +'#--------------------FN_DYNVARS_001_01------------------------#' +SET @@timestamp = DEFAULT; +'timestamp does not have any DEFAULT value' +'#---------------------FN_DYNVARS_001_02-------------------------#' +SET @@global.timestamp = "1000"; +ERROR HY000: Variable 'timestamp' is a SESSION variable and can't be used with SET GLOBAL +'#--------------------FN_DYNVARS_001_03------------------------#' +SET @@timestamp = 0; +'Setting 0 resets timestamp to session default timestamp' +SET @@timestamp = 123456789123456; +SELECT @@timestamp; +@@timestamp +123456789123456 +SET @@timestamp = 60*60*60*60*365; +SELECT @@timestamp; +@@timestamp +4730400000 +SET @@timestamp = -1000000000; +SELECT @@timestamp; +@@timestamp +18446744072709551616 +SET @temp_ts = @@timestamp - @@timestamp; +SELECT @temp_ts; +@temp_ts +0 +'#--------------------FN_DYNVARS_001_04-------------------------#' +SET @@timestamp = "100"; +ERROR 42000: Incorrect argument type to variable 'timestamp' +'Bug# 34836: Documentation says its a string variable but infact its numeric' +SET @@timestamp = " "; +ERROR 42000: Incorrect argument type to variable 'timestamp' +SET @@timestamp = 1.1; +ERROR 42000: Incorrect argument type to variable 'timestamp' +SET @@timestamp = 9999999999999999999999; +ERROR 42000: Incorrect argument type to variable 'timestamp' +'#----------------------FN_DYNVARS_001_06------------------------#' +SELECT @@timestamp = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='timestamp'; +@@timestamp = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_08-------------------------#' +SET @@timestamp = OFF; +ERROR 42000: Incorrect argument type to variable 'timestamp' +SET @@timestamp = ON; +ERROR 42000: Incorrect argument type to variable 'timestamp' +SET @@timestamp = TRUE; +SELECT @@timestamp; +@@timestamp +1 +SET @@timestamp = FALSE; +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@timestamp = 123456; +SELECT @@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp; +@@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp +1 +SET @@timestamp = 654321; +SELECT @@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp; +@@timestamp = @@local.timestamp and @@timestamp = @@session.timestamp +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET timestamp = 1; +SELECT @@timestamp; +@@timestamp +1 +SELECT local.timestamp; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.timestamp; +ERROR 42S02: Unknown table 'session' in field list +SELECT timestamp = @@session.timestamp; +ERROR 42S22: Unknown column 'timestamp' in 'field list' +SET @@timestamp = @session_start_value; diff --git a/mysql-test/r/tmp_table_size_basic_32.result b/mysql-test/r/tmp_table_size_basic_32.result new file mode 100644 index 00000000000..aeafd95ed55 --- /dev/null +++ b/mysql-test/r/tmp_table_size_basic_32.result @@ -0,0 +1,172 @@ +SET @start_global_value = @@global.tmp_table_size; +SELECT @start_global_value; +@start_global_value +16777216 +SET @start_session_value = @@session.tmp_table_size; +SELECT @start_session_value; +@start_session_value +16777216 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.tmp_table_size = 100; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '100' +SET @@global.tmp_table_size = DEFAULT; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +16777216 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +SET @@session.tmp_table_size = 200; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '200' +SET @@session.tmp_table_size = DEFAULT; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +16777216 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.tmp_table_size = DEFAULT; +SELECT @@global.tmp_table_size = 33554432; +@@global.tmp_table_size = 33554432 +0 +SET @@session.tmp_table_size = DEFAULT; +SELECT @@session.tmp_table_size = 33554432; +@@session.tmp_table_size = 33554432 +0 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.tmp_table_size = 1024; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +SET @@global.tmp_table_size = 60020; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +60020 +SET @@global.tmp_table_size = 4294967295; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +4294967295 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.tmp_table_size = 1024; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +1024 +SET @@session.tmp_table_size =4294967295; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +4294967295 +SET @@session.tmp_table_size = 65535; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +65535 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.tmp_table_size = 0; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '0' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +SET @@global.tmp_table_size = -1024; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '0' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +SET @@global.tmp_table_size = 1000; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '1000' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.tmp_table_size = ON; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@global.tmp_table_size = OFF; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@global.tmp_table_size = True; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '1' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +SET @@global.tmp_table_size = False; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '0' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +'Bug:Error should be shown that variable is numeric and can not assigned boolean value'; +SET @@global.tmp_table_size = 65530.34; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@global.tmp_table_size ="Test"; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@session.tmp_table_size = ON; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@session.tmp_table_size = OFF; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@session.tmp_table_size = True; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '1' +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +1024 +SET @@session.tmp_table_size = False; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '0' +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +1024 +SET @@session.tmp_table_size = "Test"; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@session.tmp_table_size = 12345678901; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +4294967295 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.tmp_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='tmp_table_size'; +@@global.tmp_table_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.tmp_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='tmp_table_size'; +@@session.tmp_table_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.tmp_table_size = 1024; +SET @@tmp_table_size = 4294967295; +SELECT @@tmp_table_size = @@global.tmp_table_size; +@@tmp_table_size = @@global.tmp_table_size +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@tmp_table_size = 100; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '100' +SELECT @@tmp_table_size = @@local.tmp_table_size; +@@tmp_table_size = @@local.tmp_table_size +1 +SELECT @@local.tmp_table_size = @@session.tmp_table_size; +@@local.tmp_table_size = @@session.tmp_table_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET tmp_table_size = 1027; +SELECT @@tmp_table_size; +@@tmp_table_size +1027 +SELECT local.tmp_table_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT global.tmp_table_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT tmp_table_size = @@session.tmp_table_size; +ERROR 42S22: Unknown column 'tmp_table_size' in 'field list' +SET @@global.tmp_table_size = @start_global_value; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +16777216 +SET @@session.tmp_table_size = @start_session_value; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +16777216 diff --git a/mysql-test/r/tmp_table_size_basic_64.result b/mysql-test/r/tmp_table_size_basic_64.result new file mode 100644 index 00000000000..837b90fc143 --- /dev/null +++ b/mysql-test/r/tmp_table_size_basic_64.result @@ -0,0 +1,172 @@ +SET @start_global_value = @@global.tmp_table_size; +SELECT @start_global_value; +@start_global_value +16777216 +SET @start_session_value = @@session.tmp_table_size; +SELECT @start_session_value; +@start_session_value +16777216 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.tmp_table_size = 100; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '100' +SET @@global.tmp_table_size = DEFAULT; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +16777216 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +SET @@session.tmp_table_size = 200; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '200' +SET @@session.tmp_table_size = DEFAULT; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +16777216 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.tmp_table_size = DEFAULT; +SELECT @@global.tmp_table_size = 33554432; +@@global.tmp_table_size = 33554432 +0 +SET @@session.tmp_table_size = DEFAULT; +SELECT @@session.tmp_table_size = 33554432; +@@session.tmp_table_size = 33554432 +0 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.tmp_table_size = 1024; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +SET @@global.tmp_table_size = 60020; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +60020 +SET @@global.tmp_table_size = 4294967295; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +4294967295 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.tmp_table_size = 1024; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +1024 +SET @@session.tmp_table_size =4294967295; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +4294967295 +SET @@session.tmp_table_size = 65535; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +65535 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.tmp_table_size = 0; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '0' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +SET @@global.tmp_table_size = -1024; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '0' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +SET @@global.tmp_table_size = 1000; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '1000' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.tmp_table_size = ON; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@global.tmp_table_size = OFF; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@global.tmp_table_size = True; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '1' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +SET @@global.tmp_table_size = False; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '0' +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +1024 +'Bug:Error should be shown that variable is numeric and can not assigned boolean value'; +SET @@global.tmp_table_size = 65530.34; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@global.tmp_table_size ="Test"; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@session.tmp_table_size = ON; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@session.tmp_table_size = OFF; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@session.tmp_table_size = True; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '1' +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +1024 +SET @@session.tmp_table_size = False; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '0' +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +1024 +SET @@session.tmp_table_size = "Test"; +ERROR 42000: Incorrect argument type to variable 'tmp_table_size' +SET @@session.tmp_table_size = 12345678901; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +12345678901 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.tmp_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='tmp_table_size'; +@@global.tmp_table_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.tmp_table_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='tmp_table_size'; +@@session.tmp_table_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.tmp_table_size = 1024; +SET @@tmp_table_size = 4294967295; +SELECT @@tmp_table_size = @@global.tmp_table_size; +@@tmp_table_size = @@global.tmp_table_size +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@tmp_table_size = 100; +Warnings: +Warning 1292 Truncated incorrect tmp_table_size value: '100' +SELECT @@tmp_table_size = @@local.tmp_table_size; +@@tmp_table_size = @@local.tmp_table_size +1 +SELECT @@local.tmp_table_size = @@session.tmp_table_size; +@@local.tmp_table_size = @@session.tmp_table_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET tmp_table_size = 1027; +SELECT @@tmp_table_size; +@@tmp_table_size +1027 +SELECT local.tmp_table_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT global.tmp_table_size; +ERROR 42S02: Unknown table 'global' in field list +SELECT tmp_table_size = @@session.tmp_table_size; +ERROR 42S22: Unknown column 'tmp_table_size' in 'field list' +SET @@global.tmp_table_size = @start_global_value; +SELECT @@global.tmp_table_size; +@@global.tmp_table_size +16777216 +SET @@session.tmp_table_size = @start_session_value; +SELECT @@session.tmp_table_size; +@@session.tmp_table_size +16777216 diff --git a/mysql-test/r/transaction_alloc_block_size_basic_32.result b/mysql-test/r/transaction_alloc_block_size_basic_32.result new file mode 100644 index 00000000000..706d7802ed3 --- /dev/null +++ b/mysql-test/r/transaction_alloc_block_size_basic_32.result @@ -0,0 +1,180 @@ +SET @start_global_value = @@global.transaction_alloc_block_size; +SELECT @start_global_value; +@start_global_value +8192 +SET @start_session_value = @@session.transaction_alloc_block_size; +SELECT @start_session_value; +@start_session_value +8192 +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.transaction_alloc_block_size = 100; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '100' +SET @@global.transaction_alloc_block_size = DEFAULT; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +8192 +SET @@session.transaction_alloc_block_size = 200; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '200' +SET @@session.transaction_alloc_block_size = DEFAULT; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +8192 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.transaction_alloc_block_size = DEFAULT; +SELECT @@global.transaction_alloc_block_size = 8192; +@@global.transaction_alloc_block_size = 8192 +1 +SET @@session.transaction_alloc_block_size = DEFAULT; +SELECT @@session.transaction_alloc_block_size = 8192; +@@session.transaction_alloc_block_size = 8192 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.transaction_alloc_block_size = 1024; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = 60020; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +59392 +SET @@global.transaction_alloc_block_size = 4294967295; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +4294966272 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.transaction_alloc_block_size = 1024; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +1024 +SET @@session.transaction_alloc_block_size =4294967295; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +4294966272 +SET @@session.transaction_alloc_block_size = 65535; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +64512 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.transaction_alloc_block_size = 0; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '0' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = -1024; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '0' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = 123456789201; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '123456789201' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +4294966272 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.transaction_alloc_block_size = ON; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@global.transaction_alloc_block_size = OFF; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@global.transaction_alloc_block_size = True; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '1' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = False; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '0' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = 65530.34; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@global.transaction_alloc_block_size ="Test"; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@global.transaction_alloc_block_size = 1000; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '1000' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@session.transaction_alloc_block_size = 12345678901; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '12345678901' +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +4294966272 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.transaction_alloc_block_size = ON; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@session.transaction_alloc_block_size = OFF; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@session.transaction_alloc_block_size = True; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '1' +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +1024 +SET @@session.transaction_alloc_block_size = False; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '0' +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +1024 +SET @@session.transaction_alloc_block_size = "Test"; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@session.transaction_alloc_block_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.transaction_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='transaction_alloc_block_size'; +@@global.transaction_alloc_block_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.transaction_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='transaction_alloc_block_size'; +@@session.transaction_alloc_block_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_08----------------------#' +SET @@transaction_alloc_block_size = 1024; +SET @@global.transaction_alloc_block_size = 4294967295; +SELECT @@transaction_alloc_block_size = @@global.transaction_alloc_block_size; +@@transaction_alloc_block_size = @@global.transaction_alloc_block_size +0 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@transaction_alloc_block_size = 100; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '100' +SELECT @@transaction_alloc_block_size = @@local.transaction_alloc_block_size; +@@transaction_alloc_block_size = @@local.transaction_alloc_block_size +1 +SELECT @@local.transaction_alloc_block_size = @@session.transaction_alloc_block_size; +@@local.transaction_alloc_block_size = @@session.transaction_alloc_block_size +1 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET transaction_alloc_block_size = 1027; +SELECT @@transaction_alloc_block_size; +@@transaction_alloc_block_size +1024 +SELECT local.transaction_alloc_block_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.transaction_alloc_block_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT transaction_alloc_block_size = @@session.transaction_alloc_block_size; +ERROR 42S22: Unknown column 'transaction_alloc_block_size' in 'field list' +SET @@global.transaction_alloc_block_size = @start_global_value; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +8192 +SET @@session.tmp_table_size = @start_session_value; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +1024 diff --git a/mysql-test/r/transaction_alloc_block_size_basic_64.result b/mysql-test/r/transaction_alloc_block_size_basic_64.result new file mode 100644 index 00000000000..c968d6f108c --- /dev/null +++ b/mysql-test/r/transaction_alloc_block_size_basic_64.result @@ -0,0 +1,176 @@ +SET @start_global_value = @@global.transaction_alloc_block_size; +SELECT @start_global_value; +@start_global_value +8192 +SET @start_session_value = @@session.transaction_alloc_block_size; +SELECT @start_session_value; +@start_session_value +8192 +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.transaction_alloc_block_size = 100; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '100' +SET @@global.transaction_alloc_block_size = DEFAULT; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +8192 +SET @@session.transaction_alloc_block_size = 200; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '200' +SET @@session.transaction_alloc_block_size = DEFAULT; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +8192 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.transaction_alloc_block_size = DEFAULT; +SELECT @@global.transaction_alloc_block_size = 8192; +@@global.transaction_alloc_block_size = 8192 +1 +SET @@session.transaction_alloc_block_size = DEFAULT; +SELECT @@session.transaction_alloc_block_size = 8192; +@@session.transaction_alloc_block_size = 8192 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.transaction_alloc_block_size = 1024; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = 60020; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +59392 +SET @@global.transaction_alloc_block_size = 4294967295; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +4294966272 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.transaction_alloc_block_size = 1024; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +1024 +SET @@session.transaction_alloc_block_size =4294967295; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +4294966272 +SET @@session.transaction_alloc_block_size = 65535; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +64512 +'Bug# 34877: Invalid Values are coming in variable on assigning valid values'; +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.transaction_alloc_block_size = 0; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '0' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = -1024; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '0' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = 123456789201; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +123456788480 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.transaction_alloc_block_size = ON; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@global.transaction_alloc_block_size = OFF; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@global.transaction_alloc_block_size = True; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '1' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = False; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '0' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@global.transaction_alloc_block_size = 65530.34; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@global.transaction_alloc_block_size ="Test"; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@global.transaction_alloc_block_size = 1000; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '1000' +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +1024 +SET @@session.transaction_alloc_block_size = 12345678901; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +12345678848 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@session.transaction_alloc_block_size = ON; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@session.transaction_alloc_block_size = OFF; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@session.transaction_alloc_block_size = True; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '1' +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +1024 +SET @@session.transaction_alloc_block_size = False; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '0' +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +1024 +SET @@session.transaction_alloc_block_size = "Test"; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +SET @@session.transaction_alloc_block_size = 'test'; +ERROR 42000: Incorrect argument type to variable 'transaction_alloc_block_size' +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.transaction_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='transaction_alloc_block_size'; +@@global.transaction_alloc_block_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.transaction_alloc_block_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='transaction_alloc_block_size'; +@@session.transaction_alloc_block_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_08----------------------#' +SET @@transaction_alloc_block_size = 1024; +SET @@global.transaction_alloc_block_size = 4294967295; +SELECT @@transaction_alloc_block_size = @@global.transaction_alloc_block_size; +@@transaction_alloc_block_size = @@global.transaction_alloc_block_size +0 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@transaction_alloc_block_size = 100; +Warnings: +Warning 1292 Truncated incorrect transaction_alloc_block_size value: '100' +SELECT @@transaction_alloc_block_size = @@local.transaction_alloc_block_size; +@@transaction_alloc_block_size = @@local.transaction_alloc_block_size +1 +SELECT @@local.transaction_alloc_block_size = @@session.transaction_alloc_block_size; +@@local.transaction_alloc_block_size = @@session.transaction_alloc_block_size +1 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET transaction_alloc_block_size = 1027; +SELECT @@transaction_alloc_block_size; +@@transaction_alloc_block_size +1024 +SELECT local.transaction_alloc_block_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.transaction_alloc_block_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT transaction_alloc_block_size = @@session.transaction_alloc_block_size; +ERROR 42S22: Unknown column 'transaction_alloc_block_size' in 'field list' +SET @@global.transaction_alloc_block_size = @start_global_value; +SELECT @@global.transaction_alloc_block_size; +@@global.transaction_alloc_block_size +8192 +SET @@session.tmp_table_size = @start_session_value; +SELECT @@session.transaction_alloc_block_size; +@@session.transaction_alloc_block_size +1024 diff --git a/mysql-test/r/transaction_prealloc_size_basic_32.result b/mysql-test/r/transaction_prealloc_size_basic_32.result new file mode 100644 index 00000000000..3df7a55595e --- /dev/null +++ b/mysql-test/r/transaction_prealloc_size_basic_32.result @@ -0,0 +1,172 @@ +SET @start_global_value = @@global.transaction_prealloc_size; +SELECT @start_global_value; +@start_global_value +4096 +SET @start_session_value = @@session.transaction_prealloc_size; +SELECT @start_session_value; +@start_session_value +4096 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.transaction_prealloc_size = 100; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '100' +SET @@global.transaction_prealloc_size = DEFAULT; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +4096 +SET @@session.transaction_prealloc_size = 200; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '200' +SET @@session.transaction_prealloc_size = DEFAULT; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +4096 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.transaction_prealloc_size = DEFAULT; +SELECT @@global.transaction_prealloc_size = 4096; +@@global.transaction_prealloc_size = 4096 +1 +SET @@session.transaction_prealloc_size = DEFAULT; +SELECT @@session.transaction_prealloc_size = 4096; +@@session.transaction_prealloc_size = 4096 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.transaction_prealloc_size = 1024; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@global.transaction_prealloc_size = 60020; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +59392 +SET @@global.transaction_prealloc_size = 4294966272; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +4294966272 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.transaction_prealloc_size = 1024; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +1024 +SET @@session.transaction_prealloc_size =4294966272; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +4294966272 +SET @@session.transaction_prealloc_size = 65535; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +64512 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.transaction_prealloc_size = 0; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '0' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@global.transaction_prealloc_size = -1024; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '0' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.transaction_prealloc_size = ON; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@global.transaction_prealloc_size = OFF; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@global.transaction_prealloc_size = True; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '1' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@global.transaction_prealloc_size = False; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '0' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@global.transaction_prealloc_size = 65530.34; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@global.transaction_prealloc_size ="Test"; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@global.transaction_prealloc_size = 1000; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '1000' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@session.transaction_prealloc_size = ON; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@session.transaction_prealloc_size = OFF; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@session.transaction_prealloc_size = True; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '1' +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +1024 +SET @@session.transaction_prealloc_size = False; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '0' +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +1024 +SET @@session.transaction_prealloc_size = "Test"; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@session.transaction_prealloc_size = 123456789031; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '123456789031' +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +4294966272 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.transaction_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='transaction_prealloc_size'; +@@global.transaction_prealloc_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.transaction_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='transaction_prealloc_size'; +@@session.transaction_prealloc_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.transaction_prealloc_size = 1024; +SET @@global.transaction_prealloc_size = 10; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '10' +SELECT @@transaction_prealloc_size = @@global.transaction_prealloc_size; +@@transaction_prealloc_size = @@global.transaction_prealloc_size +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@transaction_prealloc_size = 100; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '100' +SELECT @@transaction_prealloc_size = @@local.transaction_prealloc_size; +@@transaction_prealloc_size = @@local.transaction_prealloc_size +1 +SELECT @@local.transaction_prealloc_size = @@session.transaction_prealloc_size; +@@local.transaction_prealloc_size = @@session.transaction_prealloc_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET transaction_prealloc_size = 1027; +SELECT @@transaction_prealloc_size; +@@transaction_prealloc_size +1024 +SELECT local.transaction_prealloc_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.transaction_prealloc_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT transaction_prealloc_size = @@session.transaction_prealloc_size; +ERROR 42S22: Unknown column 'transaction_prealloc_size' in 'field list' +SET @@global.transaction_prealloc_size = @start_global_value; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +4096 +SET @@session.transaction_prealloc_size = @start_session_value; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +4096 diff --git a/mysql-test/r/transaction_prealloc_size_basic_64.result b/mysql-test/r/transaction_prealloc_size_basic_64.result new file mode 100644 index 00000000000..2fb6451372f --- /dev/null +++ b/mysql-test/r/transaction_prealloc_size_basic_64.result @@ -0,0 +1,170 @@ +SET @start_global_value = @@global.transaction_prealloc_size; +SELECT @start_global_value; +@start_global_value +4096 +SET @start_session_value = @@session.transaction_prealloc_size; +SELECT @start_session_value; +@start_session_value +4096 +'Bug# 34876: This variable has invalid default value as compared to documentation'; +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.transaction_prealloc_size = 100; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '100' +SET @@global.transaction_prealloc_size = DEFAULT; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +4096 +SET @@session.transaction_prealloc_size = 200; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '200' +SET @@session.transaction_prealloc_size = DEFAULT; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +4096 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.transaction_prealloc_size = DEFAULT; +SELECT @@global.transaction_prealloc_size = 4096; +@@global.transaction_prealloc_size = 4096 +1 +SET @@session.transaction_prealloc_size = DEFAULT; +SELECT @@session.transaction_prealloc_size = 4096; +@@session.transaction_prealloc_size = 4096 +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.transaction_prealloc_size = 1024; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@global.transaction_prealloc_size = 60020; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +59392 +SET @@global.transaction_prealloc_size = 4294966272; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +4294966272 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.transaction_prealloc_size = 1024; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +1024 +SET @@session.transaction_prealloc_size =4294966272; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +4294966272 +SET @@session.transaction_prealloc_size = 65535; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +64512 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.transaction_prealloc_size = 0; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '0' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@global.transaction_prealloc_size = -1024; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '0' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.transaction_prealloc_size = ON; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@global.transaction_prealloc_size = OFF; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@global.transaction_prealloc_size = True; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '1' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@global.transaction_prealloc_size = False; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '0' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@global.transaction_prealloc_size = 65530.34; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@global.transaction_prealloc_size ="Test"; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@global.transaction_prealloc_size = 1000; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '1000' +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +1024 +SET @@session.transaction_prealloc_size = ON; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@session.transaction_prealloc_size = OFF; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@session.transaction_prealloc_size = True; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '1' +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +1024 +SET @@session.transaction_prealloc_size = False; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '0' +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +1024 +SET @@session.transaction_prealloc_size = "Test"; +ERROR 42000: Incorrect argument type to variable 'transaction_prealloc_size' +SET @@session.transaction_prealloc_size = 123456789031; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +123456788480 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.transaction_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='transaction_prealloc_size'; +@@global.transaction_prealloc_size = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.transaction_prealloc_size = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='transaction_prealloc_size'; +@@session.transaction_prealloc_size = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.transaction_prealloc_size = 1024; +SET @@global.transaction_prealloc_size = 10; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '10' +SELECT @@transaction_prealloc_size = @@global.transaction_prealloc_size; +@@transaction_prealloc_size = @@global.transaction_prealloc_size +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@transaction_prealloc_size = 100; +Warnings: +Warning 1292 Truncated incorrect transaction_prealloc_size value: '100' +SELECT @@transaction_prealloc_size = @@local.transaction_prealloc_size; +@@transaction_prealloc_size = @@local.transaction_prealloc_size +1 +SELECT @@local.transaction_prealloc_size = @@session.transaction_prealloc_size; +@@local.transaction_prealloc_size = @@session.transaction_prealloc_size +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET transaction_prealloc_size = 1027; +SELECT @@transaction_prealloc_size; +@@transaction_prealloc_size +1024 +SELECT local.transaction_prealloc_size; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.transaction_prealloc_size; +ERROR 42S02: Unknown table 'session' in field list +SELECT transaction_prealloc_size = @@session.transaction_prealloc_size; +ERROR 42S22: Unknown column 'transaction_prealloc_size' in 'field list' +SET @@global.transaction_prealloc_size = @start_global_value; +SELECT @@global.transaction_prealloc_size; +@@global.transaction_prealloc_size +4096 +SET @@session.transaction_prealloc_size = @start_session_value; +SELECT @@session.transaction_prealloc_size; +@@session.transaction_prealloc_size +4096 diff --git a/mysql-test/r/wait_timeout_basic_32.result b/mysql-test/r/wait_timeout_basic_32.result new file mode 100644 index 00000000000..ae03e677e56 --- /dev/null +++ b/mysql-test/r/wait_timeout_basic_32.result @@ -0,0 +1,129 @@ +SET @start_global_value = @@global.wait_timeout; +SET @start_session_value = @@session.wait_timeout; +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.wait_timeout = 100; +SET @@global.wait_timeout = DEFAULT; +SELECT @@global.wait_timeout; +@@global.wait_timeout +28800 +SET @@session.wait_timeout = 200; +SET @@session.wait_timeout = DEFAULT; +SELECT @@session.wait_timeout; +@@session.wait_timeout +28800 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.wait_timeout = DEFAULT; +SELECT @@global.wait_timeout = @default_wait_timeout; +@@global.wait_timeout = @default_wait_timeout +1 +SET @@session.wait_timeout = DEFAULT; +SELECT @@session.wait_timeout = @default_wait_timeout; +@@session.wait_timeout = @default_wait_timeout +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.wait_timeout= 1; +SELECT @@global.wait_timeout; +@@global.wait_timeout +1 +SET @@global.wait_timeout = 60020; +SELECT @@global.wait_timeout; +@@global.wait_timeout +60020 +SET @@global.wait_timeout = 31536000; +SELECT @@global.wait_timeout = @max_wait_timeout; +@@global.wait_timeout = @max_wait_timeout +1 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.wait_timeout =6000; +SELECT @@session.wait_timeout; +@@session.wait_timeout +6000 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.wait_timeout = 0; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '0' +SET @@global.wait_timeout = -1024; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '0' +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.wait_timeout = ON; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@global.wait_timeout = OFF; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@global.wait_timeout = True; +SELECT @@global.wait_timeout; +@@global.wait_timeout +1 +SET @@global.wait_timeout = False; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '0' +SELECT @@global.wait_timeout; +@@global.wait_timeout +1 +SET @@global.wait_timeout = 65530.34; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@global.wait_timeout ="Test"; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = ON; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = OFF; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = True; +SELECT @@session.wait_timeout; +@@session.wait_timeout +1 +SET @@session.wait_timeout = False; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '0' +SELECT @@session.wait_timeout; +@@session.wait_timeout +1 +SET @@session.wait_timeout = "Test"; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = 'test'; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = 123456789031; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '123456789031' +SELECT @@session.wait_timeout = @max_wait_timeout; +@@session.wait_timeout = @max_wait_timeout +1 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.wait_timeout = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='wait_timeout'; +@@global.wait_timeout = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.wait_timeout = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='wait_timeout'; +@@session.wait_timeout = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.wait_timeout = 30000; +SET @@global.wait_timeout = 40000; +SELECT @@wait_timeout = @@global.wait_timeout; +@@wait_timeout = @@global.wait_timeout +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@wait_timeout = 100; +SELECT @@wait_timeout = @@local.wait_timeout; +@@wait_timeout = @@local.wait_timeout +1 +SELECT @@local.wait_timeout = @@session.wait_timeout; +@@local.wait_timeout = @@session.wait_timeout +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET wait_timeout = 1027; +SELECT @@wait_timeout; +@@wait_timeout +1027 +SELECT local.wait_timeout; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.wait_timeout; +ERROR 42S02: Unknown table 'session' in field list +SELECT wait_timeout = @@session.wait_timeout; +ERROR 42S22: Unknown column 'wait_timeout' in 'field list' +SET @@global.wait_timeout = @start_global_value; +SET @@session.wait_timeout = @start_session_value; diff --git a/mysql-test/r/wait_timeout_basic_64.result b/mysql-test/r/wait_timeout_basic_64.result new file mode 100644 index 00000000000..ae03e677e56 --- /dev/null +++ b/mysql-test/r/wait_timeout_basic_64.result @@ -0,0 +1,129 @@ +SET @start_global_value = @@global.wait_timeout; +SET @start_session_value = @@session.wait_timeout; +'#--------------------FN_DYNVARS_005_01-------------------------#' +SET @@global.wait_timeout = 100; +SET @@global.wait_timeout = DEFAULT; +SELECT @@global.wait_timeout; +@@global.wait_timeout +28800 +SET @@session.wait_timeout = 200; +SET @@session.wait_timeout = DEFAULT; +SELECT @@session.wait_timeout; +@@session.wait_timeout +28800 +'#--------------------FN_DYNVARS_005_02-------------------------#' +SET @@global.wait_timeout = DEFAULT; +SELECT @@global.wait_timeout = @default_wait_timeout; +@@global.wait_timeout = @default_wait_timeout +1 +SET @@session.wait_timeout = DEFAULT; +SELECT @@session.wait_timeout = @default_wait_timeout; +@@session.wait_timeout = @default_wait_timeout +1 +'#--------------------FN_DYNVARS_005_03-------------------------#' +SET @@global.wait_timeout= 1; +SELECT @@global.wait_timeout; +@@global.wait_timeout +1 +SET @@global.wait_timeout = 60020; +SELECT @@global.wait_timeout; +@@global.wait_timeout +60020 +SET @@global.wait_timeout = 31536000; +SELECT @@global.wait_timeout = @max_wait_timeout; +@@global.wait_timeout = @max_wait_timeout +1 +'#--------------------FN_DYNVARS_005_04-------------------------#' +SET @@session.wait_timeout =6000; +SELECT @@session.wait_timeout; +@@session.wait_timeout +6000 +'#------------------FN_DYNVARS_005_05-----------------------#' +SET @@global.wait_timeout = 0; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '0' +SET @@global.wait_timeout = -1024; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '0' +'Bug # 34837: Errors are not coming on assigning invalid values to variable'; +SET @@global.wait_timeout = ON; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@global.wait_timeout = OFF; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@global.wait_timeout = True; +SELECT @@global.wait_timeout; +@@global.wait_timeout +1 +SET @@global.wait_timeout = False; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '0' +SELECT @@global.wait_timeout; +@@global.wait_timeout +1 +SET @@global.wait_timeout = 65530.34; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@global.wait_timeout ="Test"; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = ON; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = OFF; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = True; +SELECT @@session.wait_timeout; +@@session.wait_timeout +1 +SET @@session.wait_timeout = False; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '0' +SELECT @@session.wait_timeout; +@@session.wait_timeout +1 +SET @@session.wait_timeout = "Test"; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = 'test'; +ERROR 42000: Incorrect argument type to variable 'wait_timeout' +SET @@session.wait_timeout = 123456789031; +Warnings: +Warning 1292 Truncated incorrect wait_timeout value: '123456789031' +SELECT @@session.wait_timeout = @max_wait_timeout; +@@session.wait_timeout = @max_wait_timeout +1 +'#------------------FN_DYNVARS_005_06-----------------------#' +SELECT @@global.wait_timeout = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES +WHERE VARIABLE_NAME='wait_timeout'; +@@global.wait_timeout = VARIABLE_VALUE +1 +'#------------------FN_DYNVARS_005_07-----------------------#' +SELECT @@session.wait_timeout = VARIABLE_VALUE +FROM INFORMATION_SCHEMA.SESSION_VARIABLES +WHERE VARIABLE_NAME='wait_timeout'; +@@session.wait_timeout = VARIABLE_VALUE +1 +'#---------------------FN_DYNVARS_001_09----------------------#' +SET @@global.wait_timeout = 30000; +SET @@global.wait_timeout = 40000; +SELECT @@wait_timeout = @@global.wait_timeout; +@@wait_timeout = @@global.wait_timeout +0 +'#---------------------FN_DYNVARS_001_10----------------------#' +SET @@wait_timeout = 100; +SELECT @@wait_timeout = @@local.wait_timeout; +@@wait_timeout = @@local.wait_timeout +1 +SELECT @@local.wait_timeout = @@session.wait_timeout; +@@local.wait_timeout = @@session.wait_timeout +1 +'#---------------------FN_DYNVARS_001_11----------------------#' +SET wait_timeout = 1027; +SELECT @@wait_timeout; +@@wait_timeout +1027 +SELECT local.wait_timeout; +ERROR 42S02: Unknown table 'local' in field list +SELECT session.wait_timeout; +ERROR 42S02: Unknown table 'session' in field list +SELECT wait_timeout = @@session.wait_timeout; +ERROR 42S22: Unknown column 'wait_timeout' in 'field list' +SET @@global.wait_timeout = @start_global_value; +SET @@session.wait_timeout = @start_session_value; diff --git a/mysql-test/t/binlog_cache_size_basic_32.test b/mysql-test/t/binlog_cache_size_basic_32.test new file mode 100644 index 00000000000..a809c00f987 --- /dev/null +++ b/mysql-test/t/binlog_cache_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/binlog_cache_size_basic.inc + diff --git a/mysql-test/t/binlog_cache_size_basic_64.test b/mysql-test/t/binlog_cache_size_basic_64.test new file mode 100644 index 00000000000..f4fdf8c2129 --- /dev/null +++ b/mysql-test/t/binlog_cache_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/binlog_cache_size_basic.inc + diff --git a/mysql-test/t/bulk_insert_buffer_size_basic_32.test b/mysql-test/t/bulk_insert_buffer_size_basic_32.test new file mode 100644 index 00000000000..76a418323bc --- /dev/null +++ b/mysql-test/t/bulk_insert_buffer_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/bulk_insert_buffer_size_basic.inc + diff --git a/mysql-test/t/bulk_insert_buffer_size_basic_64.test b/mysql-test/t/bulk_insert_buffer_size_basic_64.test new file mode 100644 index 00000000000..6363cfc12d1 --- /dev/null +++ b/mysql-test/t/bulk_insert_buffer_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/bulk_insert_buffer_size_basic.inc + diff --git a/mysql-test/t/delayed_insert_limit_basic_32.test b/mysql-test/t/delayed_insert_limit_basic_32.test new file mode 100644 index 00000000000..d7a4a81542f --- /dev/null +++ b/mysql-test/t/delayed_insert_limit_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/delayed_insert_limit_basic.inc + diff --git a/mysql-test/t/delayed_insert_limit_basic_64.test b/mysql-test/t/delayed_insert_limit_basic_64.test new file mode 100644 index 00000000000..c1d628bbb34 --- /dev/null +++ b/mysql-test/t/delayed_insert_limit_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/delayed_insert_limit_basic.inc + diff --git a/mysql-test/t/delayed_queue_size_basic_32.test b/mysql-test/t/delayed_queue_size_basic_32.test new file mode 100644 index 00000000000..06e0cf48dac --- /dev/null +++ b/mysql-test/t/delayed_queue_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/delayed_queue_size_basic.inc + diff --git a/mysql-test/t/delayed_queue_size_basic_64.test b/mysql-test/t/delayed_queue_size_basic_64.test new file mode 100644 index 00000000000..a9a929ae07b --- /dev/null +++ b/mysql-test/t/delayed_queue_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/delayed_queue_size_basic.inc + diff --git a/mysql-test/t/innodb_concurrency_tickets_basic_32.test b/mysql-test/t/innodb_concurrency_tickets_basic_32.test new file mode 100644 index 00000000000..e587d1870bf --- /dev/null +++ b/mysql-test/t/innodb_concurrency_tickets_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/innodb_concurrency_tickets_basic.inc + diff --git a/mysql-test/t/innodb_concurrency_tickets_basic_64.test b/mysql-test/t/innodb_concurrency_tickets_basic_64.test new file mode 100644 index 00000000000..bec46df3d9a --- /dev/null +++ b/mysql-test/t/innodb_concurrency_tickets_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/innodb_concurrency_tickets_basic.inc + diff --git a/mysql-test/t/innodb_max_purge_lag_basic_32.test b/mysql-test/t/innodb_max_purge_lag_basic_32.test new file mode 100644 index 00000000000..4e5b019b151 --- /dev/null +++ b/mysql-test/t/innodb_max_purge_lag_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/innodb_max_purge_lag_basic.inc + diff --git a/mysql-test/t/innodb_max_purge_lag_basic_64.test b/mysql-test/t/innodb_max_purge_lag_basic_64.test new file mode 100644 index 00000000000..5980e8ed12e --- /dev/null +++ b/mysql-test/t/innodb_max_purge_lag_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/innodb_max_purge_lag_basic.inc + diff --git a/mysql-test/t/innodb_sync_spin_loops_basic_32.test b/mysql-test/t/innodb_sync_spin_loops_basic_32.test new file mode 100644 index 00000000000..ffb766b3ec8 --- /dev/null +++ b/mysql-test/t/innodb_sync_spin_loops_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/innodb_sync_spin_loops_basic.inc + diff --git a/mysql-test/t/innodb_sync_spin_loops_basic_64.test b/mysql-test/t/innodb_sync_spin_loops_basic_64.test new file mode 100644 index 00000000000..f854bf475d6 --- /dev/null +++ b/mysql-test/t/innodb_sync_spin_loops_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/innodb_sync_spin_loops_basic.inc + diff --git a/mysql-test/t/join_buffer_size_basic_32.test b/mysql-test/t/join_buffer_size_basic_32.test new file mode 100644 index 00000000000..e904f2de426 --- /dev/null +++ b/mysql-test/t/join_buffer_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/join_buffer_size_basic.inc + diff --git a/mysql-test/t/join_buffer_size_basic_64.test b/mysql-test/t/join_buffer_size_basic_64.test new file mode 100644 index 00000000000..6de911be04c --- /dev/null +++ b/mysql-test/t/join_buffer_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/join_buffer_size_basic.inc + diff --git a/mysql-test/t/key_buffer_size_basic_32.test b/mysql-test/t/key_buffer_size_basic_32.test new file mode 100644 index 00000000000..78051382f73 --- /dev/null +++ b/mysql-test/t/key_buffer_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/key_buffer_size_basic.inc + diff --git a/mysql-test/t/key_buffer_size_basic_64.test b/mysql-test/t/key_buffer_size_basic_64.test new file mode 100644 index 00000000000..ed8409fa70c --- /dev/null +++ b/mysql-test/t/key_buffer_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/key_buffer_size_basic.inc + diff --git a/mysql-test/t/key_cache_age_threshold_basic_32.test b/mysql-test/t/key_cache_age_threshold_basic_32.test new file mode 100644 index 00000000000..13e7367f2ed --- /dev/null +++ b/mysql-test/t/key_cache_age_threshold_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/key_cache_age_threshold_basic.inc + diff --git a/mysql-test/t/key_cache_age_threshold_basic_64.test b/mysql-test/t/key_cache_age_threshold_basic_64.test new file mode 100644 index 00000000000..6524ec89127 --- /dev/null +++ b/mysql-test/t/key_cache_age_threshold_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/key_cache_age_threshold_basic.inc + diff --git a/mysql-test/t/key_cache_block_size_basic_32.test b/mysql-test/t/key_cache_block_size_basic_32.test new file mode 100644 index 00000000000..63d71016657 --- /dev/null +++ b/mysql-test/t/key_cache_block_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/key_cache_block_size_basic.inc + diff --git a/mysql-test/t/key_cache_block_size_basic_64.test b/mysql-test/t/key_cache_block_size_basic_64.test new file mode 100644 index 00000000000..0b6fb16238e --- /dev/null +++ b/mysql-test/t/key_cache_block_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/key_cache_block_size_basic.inc + diff --git a/mysql-test/t/key_cache_division_limit_basic_32.test b/mysql-test/t/key_cache_division_limit_basic_32.test new file mode 100644 index 00000000000..c8ec6cca3a3 --- /dev/null +++ b/mysql-test/t/key_cache_division_limit_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/key_cache_division_limit_basic.inc + diff --git a/mysql-test/t/key_cache_division_limit_basic_64.test b/mysql-test/t/key_cache_division_limit_basic_64.test new file mode 100644 index 00000000000..3b4e3ccaa99 --- /dev/null +++ b/mysql-test/t/key_cache_division_limit_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/key_cache_division_limit_basic.inc + diff --git a/mysql-test/t/log_warnings_basic_32.test b/mysql-test/t/log_warnings_basic_32.test new file mode 100644 index 00000000000..b6d1d0d6382 --- /dev/null +++ b/mysql-test/t/log_warnings_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/log_warnings_basic.inc + diff --git a/mysql-test/t/log_warnings_basic_64.test b/mysql-test/t/log_warnings_basic_64.test new file mode 100644 index 00000000000..c11381735be --- /dev/null +++ b/mysql-test/t/log_warnings_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/log_warnings_basic.inc + diff --git a/mysql-test/t/max_binlog_cache_size_basic_32.test b/mysql-test/t/max_binlog_cache_size_basic_32.test new file mode 100644 index 00000000000..ba9c4d5136a --- /dev/null +++ b/mysql-test/t/max_binlog_cache_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/max_binlog_cache_size_basic.inc + diff --git a/mysql-test/t/max_binlog_cache_size_basic_64.test b/mysql-test/t/max_binlog_cache_size_basic_64.test new file mode 100644 index 00000000000..ba3949ba90c --- /dev/null +++ b/mysql-test/t/max_binlog_cache_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/max_binlog_cache_size_basic.inc + diff --git a/mysql-test/t/max_connect_errors_basic_32.test b/mysql-test/t/max_connect_errors_basic_32.test new file mode 100644 index 00000000000..9f6e1dad6a8 --- /dev/null +++ b/mysql-test/t/max_connect_errors_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/max_connect_errors_basic.inc + diff --git a/mysql-test/t/max_connect_errors_basic_64.test b/mysql-test/t/max_connect_errors_basic_64.test new file mode 100644 index 00000000000..6a3d1be6978 --- /dev/null +++ b/mysql-test/t/max_connect_errors_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/max_connect_errors_basic.inc + diff --git a/mysql-test/t/max_heap_table_size_basic_32.test b/mysql-test/t/max_heap_table_size_basic_32.test new file mode 100644 index 00000000000..38684f307c2 --- /dev/null +++ b/mysql-test/t/max_heap_table_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/max_heap_table_size_basic.inc + diff --git a/mysql-test/t/max_heap_table_size_basic_64.test b/mysql-test/t/max_heap_table_size_basic_64.test new file mode 100644 index 00000000000..76f1b658da1 --- /dev/null +++ b/mysql-test/t/max_heap_table_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/max_heap_table_size_basic.inc + diff --git a/mysql-test/t/max_seeks_for_key_basic_32.test b/mysql-test/t/max_seeks_for_key_basic_32.test new file mode 100644 index 00000000000..d7b9ce7f834 --- /dev/null +++ b/mysql-test/t/max_seeks_for_key_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/max_seeks_for_key_basic.inc + diff --git a/mysql-test/t/max_seeks_for_key_basic_64.test b/mysql-test/t/max_seeks_for_key_basic_64.test new file mode 100644 index 00000000000..f700aafa044 --- /dev/null +++ b/mysql-test/t/max_seeks_for_key_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/max_seeks_for_key_basic.inc + diff --git a/mysql-test/t/max_tmp_tables_basic_32.test b/mysql-test/t/max_tmp_tables_basic_32.test new file mode 100644 index 00000000000..98da87421b7 --- /dev/null +++ b/mysql-test/t/max_tmp_tables_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/max_tmp_tables_basic.inc + diff --git a/mysql-test/t/max_tmp_tables_basic_64.test b/mysql-test/t/max_tmp_tables_basic_64.test new file mode 100644 index 00000000000..81aa478b7af --- /dev/null +++ b/mysql-test/t/max_tmp_tables_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/max_tmp_tables_basic.inc + diff --git a/mysql-test/t/max_write_lock_count_basic_32.test b/mysql-test/t/max_write_lock_count_basic_32.test new file mode 100644 index 00000000000..c33ffc53d6c --- /dev/null +++ b/mysql-test/t/max_write_lock_count_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/max_write_lock_count_basic.inc + diff --git a/mysql-test/t/max_write_lock_count_basic_64.test b/mysql-test/t/max_write_lock_count_basic_64.test new file mode 100644 index 00000000000..de1d2194c33 --- /dev/null +++ b/mysql-test/t/max_write_lock_count_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/max_write_lock_count_basic.inc + diff --git a/mysql-test/t/min_examined_row_limit_basic_32.test b/mysql-test/t/min_examined_row_limit_basic_32.test new file mode 100644 index 00000000000..bbc3b6029d8 --- /dev/null +++ b/mysql-test/t/min_examined_row_limit_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/min_examined_row_limit_basic.inc + diff --git a/mysql-test/t/min_examined_row_limit_basic_64.test b/mysql-test/t/min_examined_row_limit_basic_64.test new file mode 100644 index 00000000000..93cc4eda99d --- /dev/null +++ b/mysql-test/t/min_examined_row_limit_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/min_examined_row_limit_basic.inc + diff --git a/mysql-test/t/multi_range_count_basic_32.test b/mysql-test/t/multi_range_count_basic_32.test new file mode 100644 index 00000000000..a2487ebc154 --- /dev/null +++ b/mysql-test/t/multi_range_count_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/multi_range_count_basic.inc + diff --git a/mysql-test/t/multi_range_count_basic_64.test b/mysql-test/t/multi_range_count_basic_64.test new file mode 100644 index 00000000000..0dd1ab50e4b --- /dev/null +++ b/mysql-test/t/multi_range_count_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/multi_range_count_basic.inc + diff --git a/mysql-test/t/myisam_max_sort_file_size_basic_32.test b/mysql-test/t/myisam_max_sort_file_size_basic_32.test new file mode 100644 index 00000000000..5ff3a35a61f --- /dev/null +++ b/mysql-test/t/myisam_max_sort_file_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/myisam_max_sort_file_size_basic.inc + diff --git a/mysql-test/t/myisam_max_sort_file_size_basic_64.test b/mysql-test/t/myisam_max_sort_file_size_basic_64.test new file mode 100644 index 00000000000..e3846e2ccdc --- /dev/null +++ b/mysql-test/t/myisam_max_sort_file_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/myisam_max_sort_file_size_basic.inc + diff --git a/mysql-test/t/myisam_repair_threads_basic_32.test b/mysql-test/t/myisam_repair_threads_basic_32.test new file mode 100644 index 00000000000..7f0f0785f09 --- /dev/null +++ b/mysql-test/t/myisam_repair_threads_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/myisam_repair_threads_basic.inc + diff --git a/mysql-test/t/myisam_repair_threads_basic_64.test b/mysql-test/t/myisam_repair_threads_basic_64.test new file mode 100644 index 00000000000..f1870409c28 --- /dev/null +++ b/mysql-test/t/myisam_repair_threads_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/myisam_repair_threads_basic.inc + diff --git a/mysql-test/t/myisam_sort_buffer_size_basic_32.test b/mysql-test/t/myisam_sort_buffer_size_basic_32.test new file mode 100644 index 00000000000..d87a2015407 --- /dev/null +++ b/mysql-test/t/myisam_sort_buffer_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/myisam_sort_buffer_size_basic.inc + diff --git a/mysql-test/t/myisam_sort_buffer_size_basic_64.test b/mysql-test/t/myisam_sort_buffer_size_basic_64.test new file mode 100644 index 00000000000..fd1c3c30e7d --- /dev/null +++ b/mysql-test/t/myisam_sort_buffer_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/myisam_sort_buffer_size_basic.inc + diff --git a/mysql-test/t/net_retry_count_basic_32.test b/mysql-test/t/net_retry_count_basic_32.test new file mode 100644 index 00000000000..1f7a4f1cb80 --- /dev/null +++ b/mysql-test/t/net_retry_count_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/net_retry_count_basic.inc + diff --git a/mysql-test/t/net_retry_count_basic_64.test b/mysql-test/t/net_retry_count_basic_64.test new file mode 100644 index 00000000000..08839b673f2 --- /dev/null +++ b/mysql-test/t/net_retry_count_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/net_retry_count_basic.inc + diff --git a/mysql-test/t/query_alloc_block_size_basic_32.test b/mysql-test/t/query_alloc_block_size_basic_32.test new file mode 100644 index 00000000000..281698c4179 --- /dev/null +++ b/mysql-test/t/query_alloc_block_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/query_alloc_block_size_basic.inc + diff --git a/mysql-test/t/query_alloc_block_size_basic_64.test b/mysql-test/t/query_alloc_block_size_basic_64.test new file mode 100644 index 00000000000..70f2f37d36b --- /dev/null +++ b/mysql-test/t/query_alloc_block_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/query_alloc_block_size_basic.inc + diff --git a/mysql-test/t/query_cache_limit_basic_32.test b/mysql-test/t/query_cache_limit_basic_32.test new file mode 100644 index 00000000000..cd5f94112a0 --- /dev/null +++ b/mysql-test/t/query_cache_limit_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/query_cache_limit_basic.inc + diff --git a/mysql-test/t/query_cache_limit_basic_64.test b/mysql-test/t/query_cache_limit_basic_64.test new file mode 100644 index 00000000000..a3ebae0b244 --- /dev/null +++ b/mysql-test/t/query_cache_limit_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/query_cache_limit_basic.inc + diff --git a/mysql-test/t/query_cache_min_res_unit_basic_32.test b/mysql-test/t/query_cache_min_res_unit_basic_32.test new file mode 100644 index 00000000000..4f3740ea872 --- /dev/null +++ b/mysql-test/t/query_cache_min_res_unit_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/query_cache_min_res_unit_basic.inc + diff --git a/mysql-test/t/query_cache_min_res_unit_basic_64.test b/mysql-test/t/query_cache_min_res_unit_basic_64.test new file mode 100644 index 00000000000..b35b07d4f1e --- /dev/null +++ b/mysql-test/t/query_cache_min_res_unit_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/query_cache_min_res_unit_basic.inc + diff --git a/mysql-test/t/query_cache_size_basic_32.test b/mysql-test/t/query_cache_size_basic_32.test new file mode 100644 index 00000000000..500bdbda5dd --- /dev/null +++ b/mysql-test/t/query_cache_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/query_cache_size_basic.inc + diff --git a/mysql-test/t/query_cache_size_basic_64.test b/mysql-test/t/query_cache_size_basic_64.test new file mode 100644 index 00000000000..d53be96a28b --- /dev/null +++ b/mysql-test/t/query_cache_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/query_cache_size_basic.inc + diff --git a/mysql-test/t/query_prealloc_size_basic_32.test b/mysql-test/t/query_prealloc_size_basic_32.test new file mode 100644 index 00000000000..ae919cd8d9e --- /dev/null +++ b/mysql-test/t/query_prealloc_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/query_prealloc_size_basic.inc + diff --git a/mysql-test/t/query_prealloc_size_basic_64.test b/mysql-test/t/query_prealloc_size_basic_64.test new file mode 100644 index 00000000000..532336e225e --- /dev/null +++ b/mysql-test/t/query_prealloc_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/query_prealloc_size_basic.inc + diff --git a/mysql-test/t/range_alloc_block_size_basic_32.test b/mysql-test/t/range_alloc_block_size_basic_32.test new file mode 100644 index 00000000000..247e92cd362 --- /dev/null +++ b/mysql-test/t/range_alloc_block_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/range_alloc_block_size_basic.inc + diff --git a/mysql-test/t/range_alloc_block_size_basic_64.test b/mysql-test/t/range_alloc_block_size_basic_64.test new file mode 100644 index 00000000000..a9601d770c0 --- /dev/null +++ b/mysql-test/t/range_alloc_block_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/range_alloc_block_size_basic.inc + diff --git a/mysql-test/t/rpl_recovery_rank_basic_32.test b/mysql-test/t/rpl_recovery_rank_basic_32.test new file mode 100644 index 00000000000..d35878e153c --- /dev/null +++ b/mysql-test/t/rpl_recovery_rank_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/rpl_recovery_rank_basic.inc + diff --git a/mysql-test/t/rpl_recovery_rank_basic_64.test b/mysql-test/t/rpl_recovery_rank_basic_64.test new file mode 100644 index 00000000000..6fe04f26442 --- /dev/null +++ b/mysql-test/t/rpl_recovery_rank_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/rpl_recovery_rank_basic.inc + diff --git a/mysql-test/t/server_id_basic_32.test b/mysql-test/t/server_id_basic_32.test new file mode 100644 index 00000000000..b7c4c603803 --- /dev/null +++ b/mysql-test/t/server_id_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/server_id_basic.inc + diff --git a/mysql-test/t/server_id_basic_64.test b/mysql-test/t/server_id_basic_64.test new file mode 100644 index 00000000000..67653e0503e --- /dev/null +++ b/mysql-test/t/server_id_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/server_id_basic.inc + diff --git a/mysql-test/t/slave_transaction_retries_basic_32.test b/mysql-test/t/slave_transaction_retries_basic_32.test new file mode 100644 index 00000000000..c19297ba72f --- /dev/null +++ b/mysql-test/t/slave_transaction_retries_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/slave_transaction_retries_basic.inc + diff --git a/mysql-test/t/slave_transaction_retries_basic_64.test b/mysql-test/t/slave_transaction_retries_basic_64.test new file mode 100644 index 00000000000..e07f96edf3f --- /dev/null +++ b/mysql-test/t/slave_transaction_retries_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/slave_transaction_retries_basic.inc + diff --git a/mysql-test/t/sort_buffer_size_basic_32.test b/mysql-test/t/sort_buffer_size_basic_32.test new file mode 100644 index 00000000000..8c86fe7786a --- /dev/null +++ b/mysql-test/t/sort_buffer_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/sort_buffer_size_basic.inc + diff --git a/mysql-test/t/sort_buffer_size_basic_64.test b/mysql-test/t/sort_buffer_size_basic_64.test new file mode 100644 index 00000000000..86081b3820b --- /dev/null +++ b/mysql-test/t/sort_buffer_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/sort_buffer_size_basic.inc + diff --git a/mysql-test/t/sync_binlog_basic_32.test b/mysql-test/t/sync_binlog_basic_32.test new file mode 100644 index 00000000000..3acd76b7e72 --- /dev/null +++ b/mysql-test/t/sync_binlog_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/sync_binlog_basic.inc + diff --git a/mysql-test/t/sync_binlog_basic_64.test b/mysql-test/t/sync_binlog_basic_64.test new file mode 100644 index 00000000000..9f605445ded --- /dev/null +++ b/mysql-test/t/sync_binlog_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/sync_binlog_basic.inc + diff --git a/mysql-test/t/timestamp_basic_32.test b/mysql-test/t/timestamp_basic_32.test new file mode 100644 index 00000000000..72371c154fc --- /dev/null +++ b/mysql-test/t/timestamp_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/timestamp_basic.inc + diff --git a/mysql-test/t/timestamp_basic_64.test b/mysql-test/t/timestamp_basic_64.test new file mode 100644 index 00000000000..4614e470a4c --- /dev/null +++ b/mysql-test/t/timestamp_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/timestamp_basic.inc + diff --git a/mysql-test/t/tmp_table_size_basic_32.test b/mysql-test/t/tmp_table_size_basic_32.test new file mode 100644 index 00000000000..19d54251c5e --- /dev/null +++ b/mysql-test/t/tmp_table_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/tmp_table_size_basic.inc + diff --git a/mysql-test/t/tmp_table_size_basic_64.test b/mysql-test/t/tmp_table_size_basic_64.test new file mode 100644 index 00000000000..ddd865f6383 --- /dev/null +++ b/mysql-test/t/tmp_table_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/tmp_table_size_basic.inc + diff --git a/mysql-test/t/transaction_alloc_block_size_basic_32.test b/mysql-test/t/transaction_alloc_block_size_basic_32.test new file mode 100644 index 00000000000..a714a4f5a30 --- /dev/null +++ b/mysql-test/t/transaction_alloc_block_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/transaction_alloc_block_size_basic.inc + diff --git a/mysql-test/t/transaction_alloc_block_size_basic_64.test b/mysql-test/t/transaction_alloc_block_size_basic_64.test new file mode 100644 index 00000000000..b6ebe36c35f --- /dev/null +++ b/mysql-test/t/transaction_alloc_block_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/transaction_alloc_block_size_basic.inc + diff --git a/mysql-test/t/transaction_prealloc_size_basic_32.test b/mysql-test/t/transaction_prealloc_size_basic_32.test new file mode 100644 index 00000000000..868e281d30e --- /dev/null +++ b/mysql-test/t/transaction_prealloc_size_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/transaction_prealloc_size_basic.inc + diff --git a/mysql-test/t/transaction_prealloc_size_basic_64.test b/mysql-test/t/transaction_prealloc_size_basic_64.test new file mode 100644 index 00000000000..5487d06f521 --- /dev/null +++ b/mysql-test/t/transaction_prealloc_size_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/transaction_prealloc_size_basic.inc + diff --git a/mysql-test/t/wait_timeout_basic_32.test b/mysql-test/t/wait_timeout_basic_32.test new file mode 100644 index 00000000000..88d60333138 --- /dev/null +++ b/mysql-test/t/wait_timeout_basic_32.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 32 bit machines # +################################################################################ + +--source include/have_32bit.inc +--source include/wait_timeout_basic.inc + diff --git a/mysql-test/t/wait_timeout_basic_64.test b/mysql-test/t/wait_timeout_basic_64.test new file mode 100644 index 00000000000..76dcd6fcc91 --- /dev/null +++ b/mysql-test/t/wait_timeout_basic_64.test @@ -0,0 +1,9 @@ +################################################################################ +# Created by Horst Hunger 2008-05-07 # +# # +# Wrapper for 64 bit machines # +################################################################################ + +--source include/have_64bit.inc +--source include/wait_timeout_basic.inc + |