diff options
Diffstat (limited to 'mysql-test/include')
-rw-r--r-- | mysql-test/include/commit.inc | 4 | ||||
-rw-r--r-- | mysql-test/include/have_dynamic_loading.inc | 7 | ||||
-rw-r--r-- | mysql-test/include/have_example_plugin.inc | 5 | ||||
-rw-r--r-- | mysql-test/include/have_simple_parser.inc | 5 | ||||
-rw-r--r-- | mysql-test/include/have_udf.inc | 5 | ||||
-rw-r--r-- | mysql-test/include/mtr_warnings.sql | 11 | ||||
-rw-r--r-- | mysql-test/include/partition_date_range.inc | 69 |
7 files changed, 92 insertions, 14 deletions
diff --git a/mysql-test/include/commit.inc b/mysql-test/include/commit.inc index d412eae8364..d91ba8291fd 100644 --- a/mysql-test/include/commit.inc +++ b/mysql-test/include/commit.inc @@ -725,9 +725,9 @@ call p_verify_status_increment(4, 4, 4, 4); alter table t3 add column (b int); call p_verify_status_increment(2, 0, 2, 0); alter table t3 rename t4; -call p_verify_status_increment(1, 0, 1, 0); +call p_verify_status_increment(2, 2, 2, 2); rename table t4 to t3; -call p_verify_status_increment(1, 0, 1, 0); +call p_verify_status_increment(2, 2, 2, 2); truncate table t3; call p_verify_status_increment(4, 4, 4, 4); create view v1 as select * from t2; diff --git a/mysql-test/include/have_dynamic_loading.inc b/mysql-test/include/have_dynamic_loading.inc new file mode 100644 index 00000000000..1b2c85b3904 --- /dev/null +++ b/mysql-test/include/have_dynamic_loading.inc @@ -0,0 +1,7 @@ +# +# Whether server supports dynamic loading. +# +--require r/have_dynamic_loading.require +disable_query_log; +show variables like 'have_dynamic_loading'; +enable_query_log; diff --git a/mysql-test/include/have_example_plugin.inc b/mysql-test/include/have_example_plugin.inc index 8e57c725eb5..a2fffc17b97 100644 --- a/mysql-test/include/have_example_plugin.inc +++ b/mysql-test/include/have_example_plugin.inc @@ -2,10 +2,7 @@ # Check if server has support for loading udf's # i.e it will support dlopen # ---require r/have_dynamic_loading.require -disable_query_log; -show variables like 'have_dynamic_loading'; -enable_query_log; +--source include/have_dynamic_loading.inc # # Check if the variable EXAMPLE_PLUGIN is set diff --git a/mysql-test/include/have_simple_parser.inc b/mysql-test/include/have_simple_parser.inc index c85786bd524..5a4dc93ec81 100644 --- a/mysql-test/include/have_simple_parser.inc +++ b/mysql-test/include/have_simple_parser.inc @@ -2,10 +2,7 @@ # Check if server has support for loading udf's # i.e it will support dlopen # ---require r/have_dynamic_loading.require -disable_query_log; -show variables like 'have_dynamic_loading'; -enable_query_log; +--source include/have_dynamic_loading.inc # # Check if the variable SIMPLE_PARSER is set diff --git a/mysql-test/include/have_udf.inc b/mysql-test/include/have_udf.inc index 3f7e260c5ba..7be57bbb7a9 100644 --- a/mysql-test/include/have_udf.inc +++ b/mysql-test/include/have_udf.inc @@ -2,10 +2,7 @@ # Check if server has support for loading udf's # i.e it will support dlopen # ---require r/have_dynamic_loading.require -disable_query_log; -show variables like 'have_dynamic_loading'; -enable_query_log; +--source include/have_dynamic_loading.inc # # Check if the variable UDF_EXAMPLE_LIB is set diff --git a/mysql-test/include/mtr_warnings.sql b/mysql-test/include/mtr_warnings.sql index 2156c37f3e3..02e8d68263f 100644 --- a/mysql-test/include/mtr_warnings.sql +++ b/mysql-test/include/mtr_warnings.sql @@ -174,6 +174,17 @@ INSERT INTO global_suppressions VALUES */ ("Can't find file: '.\\\\test\\\\\\?{8}.frm'"), + /* Added 2009-08-XX after fixing Bug #42408 */ + + ("Although a path was specified for the .* option, log tables are used"), + ("Backup: Operation aborted"), + ("Restore: Operation aborted"), + ("Restore: The grant .* was skipped because the user does not exist"), + ("The path specified for the variable .* is not a directory or cannot be written:"), + ("Master server does not support or not configured semi-sync replication, fallback to asynchronous"), + (": The MySQL server is running with the --secure-backup-file-priv option so it cannot execute this statement"), + ("Slave: Unknown table 't1' Error_code: 1051"), + ("THE_LAST_SUPPRESSION")|| diff --git a/mysql-test/include/partition_date_range.inc b/mysql-test/include/partition_date_range.inc new file mode 100644 index 00000000000..5093cb3701d --- /dev/null +++ b/mysql-test/include/partition_date_range.inc @@ -0,0 +1,69 @@ +# Created for verifying bug#20577. +# expects TABLE t1 (... , a DATE, ...) + +--sorted_result +SELECT * FROM t1 WHERE a < '1001-01-01'; +--sorted_result +SELECT * FROM t1 WHERE a <= '1001-01-01'; +--sorted_result +SELECT * FROM t1 WHERE a >= '1001-01-01'; +--sorted_result +SELECT * FROM t1 WHERE a > '1001-01-01'; +--sorted_result +SELECT * FROM t1 WHERE a = '1001-01-01'; +--sorted_result +SELECT * FROM t1 WHERE a < '1001-00-00'; +--sorted_result +SELECT * FROM t1 WHERE a <= '1001-00-00'; +--sorted_result +SELECT * FROM t1 WHERE a >= '1001-00-00'; +--sorted_result +SELECT * FROM t1 WHERE a > '1001-00-00'; +--sorted_result +SELECT * FROM t1 WHERE a = '1001-00-00'; +--echo # Disabling warnings for the invalid date +--disable_warnings +--sorted_result +SELECT * FROM t1 WHERE a < '1999-02-31'; +--sorted_result +SELECT * FROM t1 WHERE a <= '1999-02-31'; +--sorted_result +SELECT * FROM t1 WHERE a >= '1999-02-31'; +--sorted_result +SELECT * FROM t1 WHERE a > '1999-02-31'; +--sorted_result +SELECT * FROM t1 WHERE a = '1999-02-31'; +--enable_warnings +--sorted_result +SELECT * FROM t1 WHERE a BETWEEN '0000-00-00' AND '1002-00-00'; +--sorted_result +SELECT * FROM t1 WHERE a BETWEEN '0000-00-00' AND '1001-01-01'; +--sorted_result +SELECT * FROM t1 WHERE a BETWEEN '0001-01-02' AND '1002-00-00'; +--sorted_result +SELECT * FROM t1 WHERE a BETWEEN '0001-01-01' AND '1001-01-01'; +if ($explain_partitions) +{ +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a < '1001-01-01'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a <= '1001-01-01'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a >= '1001-01-01'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a > '1001-01-01'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a = '1001-01-01'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a < '1001-00-00'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a <= '1001-00-00'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a >= '1001-00-00'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a > '1001-00-00'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a = '1001-00-00'; +--echo # Disabling warnings for the invalid date +--disable_warnings +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a < '1999-02-31'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a <= '1999-02-31'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a >= '1999-02-31'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a > '1999-02-31'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a = '1999-02-31'; +--enable_warnings +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a BETWEEN '0000-00-00' AND '1002-00-00'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a BETWEEN '0000-00-00' AND '1001-01-01'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a BETWEEN '0001-01-02' AND '1002-00-00'; +EXPLAIN PARTITIONS SELECT * FROM t1 WHERE a BETWEEN '0001-01-01' AND '1001-01-01'; +} |