diff options
author | Guilhem Bichot <guilhem@mysql.com> | 2008-12-10 10:02:25 +0100 |
---|---|---|
committer | Guilhem Bichot <guilhem@mysql.com> | 2008-12-10 10:02:25 +0100 |
commit | 926aaf4635c16f64d46d4fcbbbefb3aefca7a601 (patch) | |
tree | dca0acd2a01c113582c29effe5312d2ffc0fb398 /mysql-test/t | |
parent | ba816c14a9bc8012759da9d58f858f1e73bec708 (diff) | |
parent | 7f91cf0861fb4e318b973c0fe1a2e632e9b587ea (diff) | |
download | mariadb-git-926aaf4635c16f64d46d4fcbbbefb3aefca7a601.tar.gz |
Merge of 5.1-main into 5.1-maria. There were no changes to storage/myisam, mysys/mf_keycache.c, mysql-test/t/*myisam*
since previous merge. MARIA_PAGECACHE_READS in maria-preload.test are down a little bit (5%), which must be a good
side-effect of some sql/ change.
Diffstat (limited to 'mysql-test/t')
32 files changed, 177 insertions, 30 deletions
diff --git a/mysql-test/t/alter_table.test b/mysql-test/t/alter_table.test index 76d57e76491..a5460c6defd 100644 --- a/mysql-test/t/alter_table.test +++ b/mysql-test/t/alter_table.test @@ -159,7 +159,7 @@ drop table t1; # Test of ALTER TABLE DELAYED # -CREATE TABLE t1 (i int(10), index(i) ); +CREATE TABLE t1 (i int(10), index(i) ) ENGINE=MyISAM; ALTER TABLE t1 DISABLE KEYS; INSERT DELAYED INTO t1 VALUES(1),(2),(3); ALTER TABLE t1 ENABLE KEYS; diff --git a/mysql-test/t/bootstrap.test b/mysql-test/t/bootstrap.test index 203ba9b2914..a6871733c94 100644 --- a/mysql-test/t/bootstrap.test +++ b/mysql-test/t/bootstrap.test @@ -5,7 +5,6 @@ drop table if exists t1; --enable_warnings - # # Check that --bootstrap reads from stdin # diff --git a/mysql-test/t/change_user.test b/mysql-test/t/change_user.test index f200c76196c..e24ade3efd5 100644 --- a/mysql-test/t/change_user.test +++ b/mysql-test/t/change_user.test @@ -1,5 +1,6 @@ # # Bug#20023 mysql_change_user() resets the value of SQL_BIG_SELECTS +# The replace's are here to fix things for 32 bit systems # --echo Bug#20023 @@ -26,6 +27,10 @@ SET @@session.max_join_size = default; --echo change_user --change_user SELECT @@session.sql_big_selects; +--replace_result 4294967295 18446744073709551615 +SELECT @@global.max_join_size; +--replace_result 4294967295 18446744073709551615 +SELECT @@session.max_join_size; # # Bug#31418 User locks misfunctioning after mysql_change_user() diff --git a/mysql-test/t/crash_commit_before-master.opt b/mysql-test/t/crash_commit_before-master.opt index a745693594e..425fda95086 100644 --- a/mysql-test/t/crash_commit_before-master.opt +++ b/mysql-test/t/crash_commit_before-master.opt @@ -1,2 +1 @@ --skip-stack-trace --skip-core-file - diff --git a/mysql-test/t/create.test b/mysql-test/t/create.test index 2eeca1eea90..bcbd507bcdd 100644 --- a/mysql-test/t/create.test +++ b/mysql-test/t/create.test @@ -1368,9 +1368,11 @@ drop function f1; # Bug#25629 CREATE TABLE LIKE does not work with INFORMATION_SCHEMA # create table t1 like information_schema.processlist; +--replace_result ENGINE=MyISAM "" ENGINE=MARIA "" " PAGE_CHECKSUM=1" "" " PAGE_CHECKSUM=0" "" show create table t1; drop table t1; create temporary table t1 like information_schema.processlist; +--replace_result ENGINE=MyISAM "" ENGINE=MARIA "" " PAGE_CHECKSUM=1" "" " PAGE_CHECKSUM=0" "" show create table t1; drop table t1; create table t1 like information_schema.character_sets; diff --git a/mysql-test/t/delayed.test b/mysql-test/t/delayed.test index ce57645bd4b..9c7e825bc30 100644 --- a/mysql-test/t/delayed.test +++ b/mysql-test/t/delayed.test @@ -5,6 +5,15 @@ # (Can't be tested with purify :( ) # +# limit the test to engines which support INSERT DELAYED +disable_query_log; +--require r/true.require +select @@global.storage_engine in +("memory","myisam","archive","blackhole") and +@@session.storage_engine in +("memory","myisam","archive","blackhole") as `TRUE`; +enable_query_log; + --disable_warnings drop table if exists t1; --enable_warnings diff --git a/mysql-test/t/events_logs_tests-master.opt b/mysql-test/t/events_logs_tests-master.opt index 35ff7911705..73d26b7260d 100644 --- a/mysql-test/t/events_logs_tests-master.opt +++ b/mysql-test/t/events_logs_tests-master.opt @@ -1 +1 @@ ---log-slow-queries +--slow-query-log --log-output=table --general-log --general-log-file="" --slow-query-log-file="" diff --git a/mysql-test/t/events_logs_tests.test b/mysql-test/t/events_logs_tests.test index 3240dccbc76..1c296ee302b 100644 --- a/mysql-test/t/events_logs_tests.test +++ b/mysql-test/t/events_logs_tests.test @@ -75,12 +75,10 @@ create event ev_log_general on schedule at now() on completion not preserve --replace_column 1 USER_HOST select user_host, db, sql_text from mysql.slow_log where sql_text like 'select \'events_logs_test\'%'; - drop database events_test; set global event_scheduler=off; set @@global.long_query_time=default; set @@session.long_query_time=default; - # # Safety # diff --git a/mysql-test/t/fulltext.test b/mysql-test/t/fulltext.test index 21b06ca0882..4f366ad0731 100644 --- a/mysql-test/t/fulltext.test +++ b/mysql-test/t/fulltext.test @@ -445,3 +445,12 @@ EXPLAIN SELECT * FROM t1 FORCE INDEX(b) WHERE MATCH(a) AGAINST('test' IN BOOLEAN MODE) AND b=1; DROP TABLE t1; + +# +# bug#34374 - mysql generates incorrect warning +# +create table t1(a text,b date,fulltext index(a))engine=myisam; +insert into t1 set a='water',b='2008-08-04'; +select 1 from t1 where match(a) against ('water' in boolean mode) and b>='2008-08-01'; +drop table t1; +show warnings; diff --git a/mysql-test/t/log_tables-big-master.opt b/mysql-test/t/log_tables-big-master.opt index 35ff7911705..b9bc885d0e4 100644 --- a/mysql-test/t/log_tables-big-master.opt +++ b/mysql-test/t/log_tables-big-master.opt @@ -1 +1 @@ ---log-slow-queries +--log-output=table,file --slow-query-log --general-log --general-log-file="" --slow-query-log-file="" diff --git a/mysql-test/t/log_tables-master.opt b/mysql-test/t/log_tables-master.opt index 35ff7911705..4c25518cefe 100644 --- a/mysql-test/t/log_tables-master.opt +++ b/mysql-test/t/log_tables-master.opt @@ -1 +1 @@ ---log-slow-queries +--log-output=table,file --slow-query-log --general-log diff --git a/mysql-test/t/merge.test b/mysql-test/t/merge.test index dd3e4e28aeb..6e5d2aee7fd 100644 --- a/mysql-test/t/merge.test +++ b/mysql-test/t/merge.test @@ -2,6 +2,11 @@ # Test of MERGE TABLES # +# MERGE tables require MyISAM tables +let $default=`select @@global.storage_engine`; +set global storage_engine=myisam; +set session storage_engine=myisam; + --disable_warnings drop table if exists t1,t2,t3,t4,t5,t6; drop database if exists mysqltest; @@ -612,9 +617,9 @@ ALTER TABLE m1 UNION=(t1); ALTER TABLE m1 UNION=(); SHOW CREATE TABLE m1; DROP TABLE t1, m1; - --echo End of 5.0 tests + # # Bug #8306: TRUNCATE leads to index corruption # @@ -751,7 +756,7 @@ DROP TABLE t1, t2; # *after* the administration task. It was terminated by UNLOCK TABLES only. # # This is the same test case as for -# Bug#26867 - LOCK TABLES + REPAIR + merge table result in memory/cpu hogging +# Bug#26867 - LOCK TABLES REPAIR + merge table result in memory/cpu hogging # # CREATE TABLE t1 (c1 INT) ENGINE= MyISAM; @@ -1423,3 +1428,9 @@ EXPLAIN SELECT COUNT(*) FROM t4; DROP TABLE t1, t2, t3, t4; --echo End of 5.1 tests + +--disable_result_log +--disable_query_log +eval set global storage_engine=$default; +--enable_result_log +--enable_query_log diff --git a/mysql-test/t/multi_statement-master.opt b/mysql-test/t/multi_statement-master.opt index b30df037531..c735cf4c21b 100644 --- a/mysql-test/t/multi_statement-master.opt +++ b/mysql-test/t/multi_statement-master.opt @@ -1,2 +1,3 @@ ---log-slow-queries=slow.log +--slow-query-log +--slow-query-log-file=slow.log --log-queries-not-using-indexes diff --git a/mysql-test/t/myisam.test b/mysql-test/t/myisam.test index f8d9f15fab1..76d37fdc734 100644 --- a/mysql-test/t/myisam.test +++ b/mysql-test/t/myisam.test @@ -4,7 +4,7 @@ # Initialise --disable_warnings -drop table if exists t1,t2; +drop table if exists t1,t2,t3; --enable_warnings SET SQL_WARNINGS=1; @@ -1477,5 +1477,24 @@ CREATE TABLE t1 ( --exec $MYISAMCHK -d $MYSQLTEST_VARDIR/master-data/test/t1 DROP TABLE t1; ---echo End of 5.1 tests +# Test warnings with transactional=1 with MyISAM +# +create table t1 (n int not null, c char(1)) transactional=1; +show create table t1; +drop table t1; + +# +# Test of BUG#35570 CHECKSUM TABLE unreliable if LINESTRING field +# (same content / differen checksum) +# +CREATE TABLE t1 (line LINESTRING NOT NULL) engine=myisam; +INSERT INTO t1 VALUES (GeomFromText("POINT(0 0)")); +checksum table t1; +CREATE TABLE t2 (line LINESTRING NOT NULL) engine=myisam; +INSERT INTO t2 VALUES (GeomFromText("POINT(0 0)")); +checksum table t2; +CREATE TABLE t3 select * from t1; +checksum table t3; +drop table t1,t2,t3; +--echo End of 5.1 tests diff --git a/mysql-test/t/mysqldump.test b/mysql-test/t/mysqldump.test index 8084457b92b..28e3439b960 100644 --- a/mysql-test/t/mysqldump.test +++ b/mysql-test/t/mysqldump.test @@ -207,7 +207,7 @@ DROP TABLE t1; --echo # Test for --insert-ignore --echo # -CREATE TABLE t1 (a int); +CREATE TABLE t1 (a int) ENGINE=MyISAM; INSERT INTO t1 VALUES (1),(2),(3); INSERT INTO t1 VALUES (4),(5),(6); --exec $MYSQL_DUMP --skip-comments --insert-ignore test t1 @@ -1471,8 +1471,8 @@ DROP TABLE t1; # Bug #25993: crashe with a merge table and -c # -CREATE TABLE t2 (a int); -CREATE TABLE t3 (a int); +CREATE TABLE t2 (a int) ENGINE=MyISAM; +CREATE TABLE t3 (a int) ENGINE=MyISAM; CREATE TABLE t1 (a int) ENGINE=merge UNION=(t2, t3); --exec $MYSQL_DUMP --skip-comments -c test DROP TABLE t1, t2, t3; diff --git a/mysql-test/t/old-mode-master.opt b/mysql-test/t/old-mode-master.opt new file mode 100644 index 00000000000..840ee0dedcf --- /dev/null +++ b/mysql-test/t/old-mode-master.opt @@ -0,0 +1 @@ +--old=1 diff --git a/mysql-test/t/old-mode.test b/mysql-test/t/old-mode.test new file mode 100644 index 00000000000..6d0fe64bbb8 --- /dev/null +++ b/mysql-test/t/old-mode.test @@ -0,0 +1,17 @@ +# +# Test 'old' mode +# + +# Initialise +--disable_warnings +drop table if exists t1,t2; +--enable_warnings + +create table t1 (a int, b varchar(200), c text not null) checksum=1; +create table t2 (a int, b varchar(200), c text not null) checksum=0; +insert t1 values (1, "aaa", "bbb"), (NULL, "", "ccccc"), (0, NULL, ""); +insert t2 select * from t1; +checksum table t1, t2; +checksum table t1, t2 quick; +checksum table t1, t2 extended; +drop table t1,t2; diff --git a/mysql-test/t/ps-master.opt b/mysql-test/t/ps-master.opt index 3eb98fc3d6b..0e3f2e5092d 100644 --- a/mysql-test/t/ps-master.opt +++ b/mysql-test/t/ps-master.opt @@ -1 +1 @@ ---log-slow-queries --log-long-format --log-queries-not-using-indexes +--log-output=table,file --slow-query-log --log-long-format --log-queries-not-using-indexes --general-log diff --git a/mysql-test/t/query_cache.test b/mysql-test/t/query_cache.test index 88287e53b34..e77108cfa46 100644 --- a/mysql-test/t/query_cache.test +++ b/mysql-test/t/query_cache.test @@ -45,9 +45,9 @@ show status like "Qcache_queries_in_cache"; # # MERGE TABLES with INSERT/UPDATE and DELETE # -create table t1 (a int not null); +create table t1 (a int not null) ENGINE=MyISAM; insert into t1 values (1),(2),(3); -create table t2 (a int not null); +create table t2 (a int not null) ENGINE=MyISAM; insert into t2 values (4),(5),(6); create table t3 (a int not null) engine=MERGE UNION=(t1,t2) INSERT_METHOD=FIRST; # insert @@ -294,7 +294,7 @@ drop table t1; flush query cache; reset query cache; -create table t1 (a int not null); +create table t1 (a int not null) ENGINE=MyISAM; insert into t1 values (1),(2),(3); select * from t1; select * from t1; diff --git a/mysql-test/t/query_cache_debug.test b/mysql-test/t/query_cache_debug.test index 18dfe487ac3..6834301adce 100644 --- a/mysql-test/t/query_cache_debug.test +++ b/mysql-test/t/query_cache_debug.test @@ -1,4 +1,5 @@ --source include/not_embedded.inc +--source include/big_test.inc --source include/have_query_cache.inc --source include/have_debug.inc diff --git a/mysql-test/t/query_cache_merge.test b/mysql-test/t/query_cache_merge.test index 4e25bc3ed14..189de8e4092 100644 --- a/mysql-test/t/query_cache_merge.test +++ b/mysql-test/t/query_cache_merge.test @@ -19,7 +19,7 @@ let $1 = 257; while ($1) { eval drop table if exists t$1; - eval create table t$1(a int); + eval create table t$1(a int) ENGINE=MyISAM; eval insert into t$1 values (1),(2); dec $1; } diff --git a/mysql-test/t/row-checksum-old-master.opt b/mysql-test/t/row-checksum-old-master.opt new file mode 100644 index 00000000000..8e7b7f9e36f --- /dev/null +++ b/mysql-test/t/row-checksum-old-master.opt @@ -0,0 +1 @@ +--old diff --git a/mysql-test/t/row-checksum-old.test b/mysql-test/t/row-checksum-old.test new file mode 100644 index 00000000000..71188ddf432 --- /dev/null +++ b/mysql-test/t/row-checksum-old.test @@ -0,0 +1,4 @@ +# +# Run row-checksum.test with old mode +# +--source t/row-checksum.test diff --git a/mysql-test/t/row-checksum.test b/mysql-test/t/row-checksum.test new file mode 100644 index 00000000000..920a2384aa8 --- /dev/null +++ b/mysql-test/t/row-checksum.test @@ -0,0 +1,62 @@ +# +# Test checksum +# + +-- source include/have_innodb.inc +-- source include/have_maria.inc + +--disable_warnings +drop table if exists t1; +--enable_warnings + +create table t1 (a int null, v varchar(100)) engine=myisam checksum=0; +insert into t1 values(null, null), (1, "hello"); +checksum table t1; +checksum table t1 quick; +checksum table t1 extended; +drop table if exists t1; +create table t1 (a int null, v varchar(100)) engine=myisam checksum=1; +insert into t1 values(null, null), (1, "hello"); +checksum table t1; +checksum table t1 quick; +checksum table t1 extended; +drop table if exists t1; + +create table t1 (a int null, v varchar(100)) engine=innodb checksum=0; +insert into t1 values(null, null), (1, "hello"); +checksum table t1; +checksum table t1 quick; +checksum table t1 extended; +drop table t1; + +create table t1 (a int null, v varchar(100)) engine=maria checksum=0; +insert into t1 values(null, null), (1, "hello"); +checksum table t1; +checksum table t1 quick; +checksum table t1 extended; +drop table t1; +create table t1 (a int null, v varchar(100)) engine=maria checksum=1; +insert into t1 values(null, null), (1, "hello"); +checksum table t1; +checksum table t1 quick; +checksum table t1 extended; +drop table t1; + + +# +# These checksums will be different prefixes fixed sizes rows with one extra +# flag byte +# +create table t1 (a int null, v varchar(100)) engine=myisam checksum=1 row_format=fixed; +insert into t1 values(null, null), (1, "hello"); +checksum table t1; +checksum table t1 quick; +checksum table t1 extended; +drop table if exists t1; + +create table t1 (a int null, v varchar(100)) engine=innodb checksum=0 row_format=fixed; +insert into t1 values(null, null), (1, "hello"); +checksum table t1; +checksum table t1 quick; +checksum table t1 extended; +drop table t1; diff --git a/mysql-test/t/show_check-master.opt b/mysql-test/t/show_check-master.opt index 7a438da06cc..6fd0fec0e08 100644 --- a/mysql-test/t/show_check-master.opt +++ b/mysql-test/t/show_check-master.opt @@ -1 +1 @@ ---log-slow-queries --log-long-format --log-queries-not-using-indexes --myisam-recover="" +--log-output=table --slow-query-log --log-long-format --log-queries-not-using-indexes --myisam-recover="" --general-log --general-log-file="" --slow-query-log-file="" diff --git a/mysql-test/t/slow_query_log_file_basic-master.opt b/mysql-test/t/slow_query_log_file_basic-master.opt index aca191f7fea..2b6ac309d6c 100644 --- a/mysql-test/t/slow_query_log_file_basic-master.opt +++ b/mysql-test/t/slow_query_log_file_basic-master.opt @@ -1 +1 @@ ---log-slow-queries=slowtest.log +--slow-query-log --slow-query-log-file=slowtest.log diff --git a/mysql-test/t/slow_query_log_file_func-master.opt b/mysql-test/t/slow_query_log_file_func-master.opt index e5b1c0948b0..e866f016022 100644 --- a/mysql-test/t/slow_query_log_file_func-master.opt +++ b/mysql-test/t/slow_query_log_file_func-master.opt @@ -1,2 +1,2 @@ ---log-slow-queries=my_slow_test.log +--slow-query-log --slow-query-log-file=my_slow_test.log diff --git a/mysql-test/t/subselect.test b/mysql-test/t/subselect.test index 493857fb463..f27aa22533d 100644 --- a/mysql-test/t/subselect.test +++ b/mysql-test/t/subselect.test @@ -337,8 +337,8 @@ select * from t12; drop table t11, t12, t2; #insert with subselects -CREATE TABLE t1 (x int); -create table t2 (a int); +CREATE TABLE t1 (x int) ENGINE=MyISAM; +create table t2 (a int) ENGINE=MyISAM; create table t3 (b int); insert into t2 values (1); insert into t3 values (1),(2); @@ -373,7 +373,7 @@ select * from t1; drop table t1, t2, t3; #replace with subselects -CREATE TABLE t1 (x int not null, y int, primary key (x)); +CREATE TABLE t1 (x int not null, y int, primary key (x)) ENGINE=MyISAM; create table t2 (a int); create table t3 (a int); insert into t2 values (1); diff --git a/mysql-test/t/subselect_debug.test b/mysql-test/t/subselect_debug.test index 358705da4f2..c2a7bafe1cd 100644 --- a/mysql-test/t/subselect_debug.test +++ b/mysql-test/t/subselect_debug.test @@ -9,8 +9,9 @@ CREATE TABLE t1(id INT); INSERT INTO t1 VALUES (1),(2),(3),(4); INSERT INTO t1 SELECT a.id FROM t1 a,t1 b,t1 c,t1 d; # Setup the mysqld to crash at certain point +SET @orig_debug=@@debug; SET SESSION debug="d,subselect_exec_fail"; SELECT SUM(EXISTS(SELECT RAND() FROM t1)) FROM t1; SELECT REVERSE(EXISTS(SELECT RAND() FROM t1)); -SET SESSION debug=DEFAULT; +SET SESSION debug=@orig_debug; DROP TABLE t1; diff --git a/mysql-test/t/sync_frm_basic.test b/mysql-test/t/sync_frm_basic.test index 6c00182a805..af268fd2c44 100644 --- a/mysql-test/t/sync_frm_basic.test +++ b/mysql-test/t/sync_frm_basic.test @@ -34,6 +34,8 @@ ################################################################ SET @start_value = @@global.sync_frm; +# In some cases the server may have been started with --disable-sync-frm +--replace_column 1 VAL SELECT @start_value; @@ -155,9 +157,9 @@ SELECT sync_frm = @@session.sync_frm; ############################## SET @@global.sync_frm = @start_value; +--replace_column 1 VAL SELECT @@global.sync_frm; - ###################################################### # END OF sync_frm TESTS # ###################################################### diff --git a/mysql-test/t/union-master.opt b/mysql-test/t/union-master.opt index 3eb98fc3d6b..4ddf5c3734a 100644 --- a/mysql-test/t/union-master.opt +++ b/mysql-test/t/union-master.opt @@ -1 +1 @@ ---log-slow-queries --log-long-format --log-queries-not-using-indexes +--slow-query-log --log-long-format --log-queries-not-using-indexes diff --git a/mysql-test/t/variables-big.test b/mysql-test/t/variables-big.test index 43326f3d016..2dacabfece7 100644 --- a/mysql-test/t/variables-big.test +++ b/mysql-test/t/variables-big.test @@ -9,12 +9,18 @@ # set session transaction_prealloc_size=1024*1024*1024*1; +--replace_column 1 # show processlist; set session transaction_prealloc_size=1024*1024*1024*2; +--replace_column 1 # show processlist; +--replace_column 1 # set session transaction_prealloc_size=1024*1024*1024*3; +--replace_column 1 # show processlist; set session transaction_prealloc_size=1024*1024*1024*4; +--replace_column 1 # show processlist; set session transaction_prealloc_size=1024*1024*1024*5; +--replace_column 1 # show processlist; |