mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Final fix for bug#38349: Did the changes due to the 2 reviews.
- Updated slow_query_log_file_basic and general_log_file basis instead of the func version as the func version run good but the basic versions fail. - Sent innodb.test to dev@innodb.com. - variables.test has differences probably due to a bug in mtr or in the SET statement (see bug#39369). - general_log_file_basic.test and slow_query_log_file_bsaic.test have differences, which might be produced by the new mtr (see bug#38124).
This commit is contained in:
@ -14,16 +14,18 @@
|
||||
# Description: Test Cases of Dynamic System Variable myisam_stats_method #
|
||||
# that checks the behavior of this variable #
|
||||
# #
|
||||
# Reference: http://dev.mysql.com/doc/refman/5.1/en/ #
|
||||
# server-system-variables.html #
|
||||
# Reference: #
|
||||
# http://dev.mysql.com/doc/refman/5.1/en/server-system-variables.html #
|
||||
# #
|
||||
###############################################################################
|
||||
|
||||
--echo '#--------------------FN_DYNVARS_097_01-------------------------#'
|
||||
#####################################################################
|
||||
# Check if Setting myisam_stats_method is changed in new connection #
|
||||
# Check if Setting myisam_stats_method is changed in new connection #
|
||||
#####################################################################
|
||||
|
||||
SET @start_value = @@global.myisam_stats_method;
|
||||
|
||||
SET @@global.myisam_stats_method = nulls_equal;
|
||||
--echo 'connect (con1,localhost,root,,,,)'
|
||||
connect (con1,localhost,root,,,,);
|
||||
@ -45,19 +47,19 @@ connection default;
|
||||
DROP TABLE IF EXISTS t1;
|
||||
--enable_warnings
|
||||
|
||||
CREATE TABLE t1 (a int, key (a));
|
||||
CREATE TABLE t1 (a INT, KEY (a));
|
||||
INSERT INTO t1 VALUES (0),(1),(2),(3),(4);
|
||||
INSERT INTO t1 SELECT NULL FROM t1;
|
||||
|
||||
#=======================================
|
||||
--echo 'default: NULLs considered unequal'
|
||||
#=======================================
|
||||
SET myisam_stats_method=nulls_unequal;
|
||||
SET myisam_stats_method = nulls_unequal;
|
||||
|
||||
ANALYZE TABLE t1;
|
||||
SHOW INDEX FROM t1;
|
||||
INSERT INTO t1 VALUES (11);
|
||||
DELETE FROM t1 WHERE a=11;
|
||||
DELETE FROM t1 WHERE a = 11;
|
||||
CHECK TABLE t1;
|
||||
SHOW INDEX FROM t1;
|
||||
|
||||
@ -65,14 +67,14 @@ SHOW INDEX FROM t1;
|
||||
#=====================================
|
||||
--echo 'Set nulls to be equal'
|
||||
#=====================================
|
||||
SET myisam_stats_method=nulls_equal;
|
||||
SET myisam_stats_method = nulls_equal;
|
||||
|
||||
INSERT INTO t1 VALUES (11);
|
||||
DELETE FROM t1 WHERE a=11;
|
||||
ANALYZE TABLE t1;
|
||||
DELETE FROM t1 WHERE a = 11;
|
||||
ANALYZE TABLE t1;
|
||||
SHOW INDEX FROM t1;
|
||||
INSERT INTO t1 VALUES (11);
|
||||
DELETE FROM t1 WHERE a=11;
|
||||
DELETE FROM t1 WHERE a = 11;
|
||||
CHECK TABLE t1;
|
||||
SHOW INDEX FROM t1;
|
||||
|
||||
@ -80,13 +82,13 @@ SHOW INDEX FROM t1;
|
||||
--echo 'Set nulls to be ignored'
|
||||
#=====================================
|
||||
|
||||
SET myisam_stats_method=nulls_ignored;
|
||||
SHOW variables LIKE 'myisam_stats_method';
|
||||
drop TABLE t1;
|
||||
SET myisam_stats_method = nulls_ignored;
|
||||
SHOW VARIABLES LIKE 'myisam_stats_method';
|
||||
DROP TABLE t1;
|
||||
|
||||
CREATE TABLE t1 (
|
||||
a char(3), b char(4), c char(5), d char(6),
|
||||
key(a,b,c,d)
|
||||
a CHAR(3), b CHAR(4), c CHAR(5), d CHAR(6),
|
||||
KEY(a,b,c,d)
|
||||
);
|
||||
INSERT INTO t1 VALUES ('bcd','def1', NULL, 'zz');
|
||||
INSERT INTO t1 VALUES ('bcd','def2', NULL, 'zz');
|
||||
@ -98,9 +100,12 @@ DELETE FROM t1;
|
||||
ANALYZE TABLE t1;
|
||||
SHOW INDEX FROM t1;
|
||||
|
||||
SET myisam_stats_method=DEFAULT;
|
||||
SET myisam_stats_method = DEFAULT;
|
||||
DROP TABLE t1;
|
||||
|
||||
SET @@global.myisam_stats_method= @start_value;
|
||||
|
||||
########################################################
|
||||
# End of functionality Testing for myisam_stats_method #
|
||||
########################################################
|
||||
|
||||
|
Reference in New Issue
Block a user