From b7f11d10685e8254475cac208d5adb9420fb5075 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 21 Dec 2009 17:26:36 +0100 Subject: [PATCH 1/5] Don't include the `innodb' suite in the list of default test suites. This suite is for the innodb plugin, which we do not use in MariaDB (we instead have XtraDB as default storage engine, which includes the innodb plugin). We have included the same tests in the main suite, so no point in running them twice (and most of them are disabled anyway due to the absense of the innodb plugin). --- mysql-test/mysql-test-run.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mysql-test/mysql-test-run.pl b/mysql-test/mysql-test-run.pl index 3ef111273a0..428557e6714 100755 --- a/mysql-test/mysql-test-run.pl +++ b/mysql-test/mysql-test-run.pl @@ -126,7 +126,7 @@ my $path_config_file; # The generated config file, var/my.cnf # executables will be used by the test suite. our $opt_vs_config = $ENV{'MTR_VS_CONFIG'}; -my $DEFAULT_SUITES= "main,binlog,federated,rpl,innodb,maria,parts"; +my $DEFAULT_SUITES= "main,binlog,federated,rpl,maria,parts"; my $opt_suites; our $opt_verbose= 0; # Verbose output, enable with --verbose From 85d78b62ccf99fc93ec40f994658dc394a3e5987 Mon Sep 17 00:00:00 2001 From: Michael Widenius Date: Sun, 27 Dec 2009 15:54:41 +0200 Subject: [PATCH 2/5] Fix test suite so that it works when doing configure --without-uca Simplify testing of needed characterset Remove ndb from --with-plugins=max build mysqlbug now sends email to maria-developers@lists.launchpad.net client/mysqltest.cc: SKIP now expands variables (for better error messages) mysql-test/include/have_big5.inc: Simplify by using have_collation.inc mysql-test/include/have_collation.inc: Test if '$collation' is supported mysql-test/include/have_cp1250_ch.inc: Simplify by using have_collation.inc mysql-test/include/have_cp1251.inc: Simplify by using have_collation.inc mysql-test/include/have_cp866.inc: Simplify by using have_collation.inc mysql-test/include/have_cp932.inc: Simplify by using have_collation.inc mysql-test/include/have_eucjpms.inc: Simplify by using have_collation.inc mysql-test/include/have_euckr.inc: Simplify by using have_collation.inc mysql-test/include/have_gb2312.inc: Simplify by using have_collation.inc mysql-test/include/have_gbk.inc: Simplify by using have_collation.inc mysql-test/include/have_koi8r.inc: Simplify by using have_collation.inc mysql-test/include/have_latin2_ch.inc: Simplify by using have_collation.inc mysql-test/include/have_sjis.inc: Simplify by using have_collation.inc mysql-test/include/have_tis620.inc: Simplify by using have_collation.inc mysql-test/include/have_ucs2.inc: Simplify by using have_collation.inc mysql-test/include/have_ujis.inc: Simplify by using have_collation.inc mysql-test/include/have_utf8.inc: Simplify by using have_collation.inc mysql-test/r/create-uca.result: Create tests that uses unicode mysql-test/r/create.result: Move test with unicode to create-uca.test mysql-test/r/have_big5.require: Not needed anymore mysql-test/r/have_cp1250_ch.require: Not needed anymore mysql-test/r/have_cp1251.require: Not needed anymore mysql-test/r/have_cp866.require: Not needed anymore mysql-test/r/have_cp932.require: Not needed anymore mysql-test/r/have_eucjpms.require: Not needed anymore mysql-test/r/have_euckr.require: Not needed anymore mysql-test/r/have_gb2312.require: Not needed anymore mysql-test/r/have_gbk.require: Not needed anymore mysql-test/r/have_koi8r.require: Not needed anymore mysql-test/r/have_latin2_ch.require: Not needed anymore mysql-test/r/have_sjis.require: Not needed anymore mysql-test/r/have_tis620.require: Not needed anymore mysql-test/r/have_ucs2.require: Not needed anymore mysql-test/r/have_ujis.require: Not needed anymore mysql-test/r/have_utf8.require: Not needed anymore mysql-test/r/innodb.result: Move tests that depends on unicode to innodb_utf8.test mysql-test/r/innodb_utf8.result: Test moved from innodb.test mysql-test/suite/rpl/t/rpl_ignore_table.test: Test for required collations mysql-test/t/create-uca.test: Create tests that uses unicode mysql-test/t/create.test: Move test with unicode to create-uca.test mysql-test/t/ctype_utf8.test: Test that require unicode mysql-test/t/ddl_i18n_koi8r.test: Test for required collations mysql-test/t/ddl_i18n_utf8.test: Test for required collations mysql-test/t/fulltext.test: Test for required collations mysql-test/t/fulltext2.test: Test for required collations mysql-test/t/innodb.test: Move tests that depends on unicode to innodb_utf8.test mysql-test/t/innodb_utf8.test: Tests that uses unicode mysql-test/t/query_cache_ps_no_prot.test: Test for required collations mysql-test/t/query_cache_ps_ps_prot.test: Test for required collations scripts/mysqlbug.sh: Send emails to maria-developers@lists.launchpad.net storage/ndb/plug.in: Don't include ndb in 'max' builds --- client/mysqltest.cc | 6 ++- mysql-test/include/have_big5.inc | 6 +-- mysql-test/include/have_collation.inc | 3 ++ mysql-test/include/have_cp1250_ch.inc | 6 +-- mysql-test/include/have_cp1251.inc | 9 +--- mysql-test/include/have_cp866.inc | 9 +--- mysql-test/include/have_cp932.inc | 6 +-- mysql-test/include/have_eucjpms.inc | 6 +-- mysql-test/include/have_euckr.inc | 6 +-- mysql-test/include/have_gb2312.inc | 6 +-- mysql-test/include/have_gbk.inc | 6 +-- mysql-test/include/have_koi8r.inc | 9 +--- mysql-test/include/have_latin2_ch.inc | 6 +-- mysql-test/include/have_sjis.inc | 6 +-- mysql-test/include/have_tis620.inc | 6 +-- mysql-test/include/have_ucs2.inc | 6 +-- mysql-test/include/have_ujis.inc | 6 +-- mysql-test/include/have_utf8.inc | 9 +--- mysql-test/r/create-uca.result | 31 +++++++++++++ mysql-test/r/create.result | 46 -------------------- mysql-test/r/have_big5.require | 2 - mysql-test/r/have_cp1250_ch.require | 2 - mysql-test/r/have_cp1251.require | 2 - mysql-test/r/have_cp866.require | 2 - mysql-test/r/have_cp932.require | 2 - mysql-test/r/have_eucjpms.require | 2 - mysql-test/r/have_euckr.require | 2 - mysql-test/r/have_gb2312.require | 2 - mysql-test/r/have_gbk.require | 2 - mysql-test/r/have_koi8r.require | 2 - mysql-test/r/have_latin2_ch.require | 2 - mysql-test/r/have_sjis.require | 2 - mysql-test/r/have_tis620.require | 2 - mysql-test/r/have_ucs2.require | 2 - mysql-test/r/have_ujis.require | 2 - mysql-test/r/have_utf8.require | 2 - mysql-test/r/innodb.result | 9 ---- mysql-test/r/innodb_utf8.result | 10 +++++ mysql-test/suite/rpl/t/rpl_ignore_table.test | 2 + mysql-test/t/create-uca.test | 26 +++++++++++ mysql-test/t/create.test | 46 -------------------- mysql-test/t/ctype_utf8.test | 9 ++++ mysql-test/t/ddl_i18n_koi8r.test | 2 + mysql-test/t/ddl_i18n_utf8.test | 2 + mysql-test/t/fulltext.test | 3 ++ mysql-test/t/fulltext2.test | 3 ++ mysql-test/t/innodb.test | 12 ----- mysql-test/t/innodb_utf8.test | 24 ++++++++++ mysql-test/t/query_cache_ps_no_prot.test | 3 +- mysql-test/t/query_cache_ps_ps_prot.test | 3 +- scripts/mysqlbug.sh | 2 +- storage/ndb/plug.in | 2 +- 52 files changed, 158 insertions(+), 226 deletions(-) create mode 100644 mysql-test/include/have_collation.inc create mode 100644 mysql-test/r/create-uca.result delete mode 100644 mysql-test/r/have_big5.require delete mode 100644 mysql-test/r/have_cp1250_ch.require delete mode 100644 mysql-test/r/have_cp1251.require delete mode 100644 mysql-test/r/have_cp866.require delete mode 100644 mysql-test/r/have_cp932.require delete mode 100644 mysql-test/r/have_eucjpms.require delete mode 100644 mysql-test/r/have_euckr.require delete mode 100644 mysql-test/r/have_gb2312.require delete mode 100644 mysql-test/r/have_gbk.require delete mode 100644 mysql-test/r/have_koi8r.require delete mode 100644 mysql-test/r/have_latin2_ch.require delete mode 100644 mysql-test/r/have_sjis.require delete mode 100644 mysql-test/r/have_tis620.require delete mode 100644 mysql-test/r/have_ucs2.require delete mode 100644 mysql-test/r/have_ujis.require delete mode 100644 mysql-test/r/have_utf8.require create mode 100644 mysql-test/r/innodb_utf8.result create mode 100644 mysql-test/t/create-uca.test create mode 100644 mysql-test/t/innodb_utf8.test diff --git a/client/mysqltest.cc b/client/mysqltest.cc index 8360b33b031..bc5c4ed76b8 100644 --- a/client/mysqltest.cc +++ b/client/mysqltest.cc @@ -1267,6 +1267,7 @@ void abort_not_supported_test(const char *fmt, ...) DBUG_ENTER("abort_not_supported_test"); /* Print include filestack */ + fflush(stdout); fprintf(stderr, "The test '%s' is not supported by this installation\n", file_stack->file_name); fprintf(stderr, "Detected in file %s at line %d\n", @@ -8098,7 +8099,10 @@ int main(int argc, char **argv) abort_flag= 1; break; case Q_SKIP: - abort_not_supported_test("%s", command->first_argument); + /* Eval the query, thus replacing all environment variables */ + dynstr_set(&ds_res, 0); + do_eval(&ds_res, command->first_argument, command->end, FALSE); + abort_not_supported_test("%s",ds_res.str); break; case Q_RESULT: diff --git a/mysql-test/include/have_big5.inc b/mysql-test/include/have_big5.inc index dad4a0a8eeb..d6ef1202bae 100644 --- a/mysql-test/include/have_big5.inc +++ b/mysql-test/include/have_big5.inc @@ -1,4 +1,2 @@ --- require r/have_big5.require -disable_query_log; -show collation like 'big5_chinese_ci'; -enable_query_log; +let collation=big5_chinese_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_collation.inc b/mysql-test/include/have_collation.inc new file mode 100644 index 00000000000..99270fd4d3d --- /dev/null +++ b/mysql-test/include/have_collation.inc @@ -0,0 +1,3 @@ +if (!`SELECT count(*) AS 'true' FROM information_schema.collations WHERE collation_name LIKE '$collation'`) { + skip Test needs character set '$collation'; +} diff --git a/mysql-test/include/have_cp1250_ch.inc b/mysql-test/include/have_cp1250_ch.inc index 426fa658597..93fde6e9fe6 100644 --- a/mysql-test/include/have_cp1250_ch.inc +++ b/mysql-test/include/have_cp1250_ch.inc @@ -1,4 +1,2 @@ --- require r/have_cp1250_ch.require -disable_query_log; -show collation like 'cp1250_czech_cs'; -enable_query_log; +let collation=cp1250_czech_cs; +--source include/have_collation.inc diff --git a/mysql-test/include/have_cp1251.inc b/mysql-test/include/have_cp1251.inc index 2d5f1b3b529..32e9e7220fc 100644 --- a/mysql-test/include/have_cp1251.inc +++ b/mysql-test/include/have_cp1251.inc @@ -1,7 +1,2 @@ ---require r/have_cp1251.require - ---disable_query_log - -SHOW COLLATION LIKE 'cp1251_general_ci'; - ---enable_query_log +let collation=cp1251_general_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_cp866.inc b/mysql-test/include/have_cp866.inc index 27390d87d51..549ea22a0e3 100644 --- a/mysql-test/include/have_cp866.inc +++ b/mysql-test/include/have_cp866.inc @@ -1,7 +1,2 @@ ---require r/have_cp866.require - ---disable_query_log - -SHOW COLLATION LIKE 'cp866_general_ci'; - ---enable_query_log +let collation=cp866_general_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_cp932.inc b/mysql-test/include/have_cp932.inc index ecad979c02a..6e436b8b3f5 100644 --- a/mysql-test/include/have_cp932.inc +++ b/mysql-test/include/have_cp932.inc @@ -1,4 +1,2 @@ --- require r/have_cp932.require -disable_query_log; -show collation like 'cp932_japanese_ci'; -enable_query_log; +let collation=cp932_japanese_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_eucjpms.inc b/mysql-test/include/have_eucjpms.inc index 6d96eefcc31..c38af5299c7 100644 --- a/mysql-test/include/have_eucjpms.inc +++ b/mysql-test/include/have_eucjpms.inc @@ -1,4 +1,2 @@ --- require r/have_eucjpms.require -disable_query_log; -show collation like 'eucjpms_japanese_ci'; -enable_query_log; +let collation=eucjpms_japanese_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_euckr.inc b/mysql-test/include/have_euckr.inc index 4b4e870cf47..4da1a8363a3 100644 --- a/mysql-test/include/have_euckr.inc +++ b/mysql-test/include/have_euckr.inc @@ -1,4 +1,2 @@ --- require r/have_euckr.require -disable_query_log; -show collation like 'euckr_korean_ci'; -enable_query_log; +let collation=euckr_korean_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_gb2312.inc b/mysql-test/include/have_gb2312.inc index 27591c01b6c..6a9a0588be0 100644 --- a/mysql-test/include/have_gb2312.inc +++ b/mysql-test/include/have_gb2312.inc @@ -1,4 +1,2 @@ --- require r/have_gb2312.require -disable_query_log; -show collation like 'gb2312_chinese_ci'; -enable_query_log; +let collation=gb2312_chinese_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_gbk.inc b/mysql-test/include/have_gbk.inc index 72252d6b00d..b8177aa655d 100644 --- a/mysql-test/include/have_gbk.inc +++ b/mysql-test/include/have_gbk.inc @@ -1,4 +1,2 @@ --- require r/have_gbk.require -disable_query_log; -show collation like 'gbk_chinese_ci'; -enable_query_log; +let collation=gbk_chinese_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_koi8r.inc b/mysql-test/include/have_koi8r.inc index 1fe163565ba..02647f4555f 100644 --- a/mysql-test/include/have_koi8r.inc +++ b/mysql-test/include/have_koi8r.inc @@ -1,7 +1,2 @@ ---require r/have_koi8r.require - ---disable_query_log - -SHOW COLLATION LIKE 'koi8r_general_ci'; - ---enable_query_log +let collation=koi8r_general_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_latin2_ch.inc b/mysql-test/include/have_latin2_ch.inc index 215715a6aaf..f1e0d4e26aa 100644 --- a/mysql-test/include/have_latin2_ch.inc +++ b/mysql-test/include/have_latin2_ch.inc @@ -1,4 +1,2 @@ --- require r/have_latin2_ch.require -disable_query_log; -show collation like 'latin2_czech_cs'; -enable_query_log; +let collation=latin2_czech_cs; +--source include/have_collation.inc diff --git a/mysql-test/include/have_sjis.inc b/mysql-test/include/have_sjis.inc index ac6531ca868..a25dc51dfa7 100644 --- a/mysql-test/include/have_sjis.inc +++ b/mysql-test/include/have_sjis.inc @@ -1,4 +1,2 @@ --- require r/have_sjis.require -disable_query_log; -show collation like 'sjis_japanese_ci'; -enable_query_log; +let collation=sjis_japanese_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_tis620.inc b/mysql-test/include/have_tis620.inc index ad5ba9dea69..d385ff2c621 100644 --- a/mysql-test/include/have_tis620.inc +++ b/mysql-test/include/have_tis620.inc @@ -1,4 +1,2 @@ --- require r/have_tis620.require -disable_query_log; -show collation like 'tis620_thai_ci'; -enable_query_log; +let collation=tis620_thai_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_ucs2.inc b/mysql-test/include/have_ucs2.inc index 324ed52dd02..885e20297aa 100644 --- a/mysql-test/include/have_ucs2.inc +++ b/mysql-test/include/have_ucs2.inc @@ -1,4 +1,2 @@ --- require r/have_ucs2.require -disable_query_log; -show collation like 'ucs2_general_ci'; -enable_query_log; +let collation=ucs2_general_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_ujis.inc b/mysql-test/include/have_ujis.inc index e4b2f50cf93..222c027ca5a 100644 --- a/mysql-test/include/have_ujis.inc +++ b/mysql-test/include/have_ujis.inc @@ -1,4 +1,2 @@ --- require r/have_ujis.require -disable_query_log; -show collation like 'ujis_japanese_ci'; -enable_query_log; +let collation=ujis_japanese_ci; +--source include/have_collation.inc diff --git a/mysql-test/include/have_utf8.inc b/mysql-test/include/have_utf8.inc index 58b74f4072f..177d39abfdc 100644 --- a/mysql-test/include/have_utf8.inc +++ b/mysql-test/include/have_utf8.inc @@ -1,7 +1,2 @@ ---require r/have_utf8.require - ---disable_query_log - -SHOW COLLATION LIKE 'utf8_general_ci'; - ---enable_query_log +let collation=utf8_general_ci; +--source include/have_collation.inc diff --git a/mysql-test/r/create-uca.result b/mysql-test/r/create-uca.result new file mode 100644 index 00000000000..2d2522a36a3 --- /dev/null +++ b/mysql-test/r/create-uca.result @@ -0,0 +1,31 @@ +drop table if exists t1,t2; +CREATE TABLE t1( +c1 INT DEFAULT 12 COMMENT 'column1', +c2 INT NULL COMMENT 'column2', +c3 INT NOT NULL COMMENT 'column3', +c4 VARCHAR(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a', +c5 VARCHAR(255) COLLATE utf8_unicode_ci NULL DEFAULT 'b', +c6 VARCHAR(255)) +COLLATE latin1_bin; +SHOW CREATE TABLE t1; +Table Create Table +t1 CREATE TABLE `t1` ( + `c1` int(11) DEFAULT '12' COMMENT 'column1', + `c2` int(11) DEFAULT NULL COMMENT 'column2', + `c3` int(11) NOT NULL COMMENT 'column3', + `c4` varchar(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a', + `c5` varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci DEFAULT 'b', + `c6` varchar(255) COLLATE latin1_bin DEFAULT NULL +) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin +CREATE TABLE t2 AS SELECT * FROM t1; +SHOW CREATE TABLE t2; +Table Create Table +t2 CREATE TABLE `t2` ( + `c1` int(11) DEFAULT '12' COMMENT 'column1', + `c2` int(11) DEFAULT NULL COMMENT 'column2', + `c3` int(11) NOT NULL COMMENT 'column3', + `c4` varchar(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a', + `c5` varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci DEFAULT 'b', + `c6` varchar(255) CHARACTER SET latin1 COLLATE latin1_bin DEFAULT NULL +) ENGINE=MyISAM DEFAULT CHARSET=latin1 +DROP TABLE t1,t2; diff --git a/mysql-test/r/create.result b/mysql-test/r/create.result index 29686d6e023..dc2cb6786c7 100644 --- a/mysql-test/r/create.result +++ b/mysql-test/r/create.result @@ -1792,52 +1792,6 @@ t1 CREATE TABLE `t1` ( ) ENGINE=MEMORY DEFAULT CHARSET=utf8 drop table t1; -# -- -# -- Bug#21380: DEFAULT definition not always transfered by CREATE -# -- TABLE/SELECT to the new table. -# -- - -DROP TABLE IF EXISTS t1; -DROP TABLE IF EXISTS t2; - -CREATE TABLE t1( -c1 INT DEFAULT 12 COMMENT 'column1', -c2 INT NULL COMMENT 'column2', -c3 INT NOT NULL COMMENT 'column3', -c4 VARCHAR(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a', -c5 VARCHAR(255) COLLATE utf8_unicode_ci NULL DEFAULT 'b', -c6 VARCHAR(255)) -COLLATE latin1_bin; - -SHOW CREATE TABLE t1; -Table Create Table -t1 CREATE TABLE `t1` ( - `c1` int(11) DEFAULT '12' COMMENT 'column1', - `c2` int(11) DEFAULT NULL COMMENT 'column2', - `c3` int(11) NOT NULL COMMENT 'column3', - `c4` varchar(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a', - `c5` varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci DEFAULT 'b', - `c6` varchar(255) COLLATE latin1_bin DEFAULT NULL -) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin - -CREATE TABLE t2 AS SELECT * FROM t1; - -SHOW CREATE TABLE t2; -Table Create Table -t2 CREATE TABLE `t2` ( - `c1` int(11) DEFAULT '12' COMMENT 'column1', - `c2` int(11) DEFAULT NULL COMMENT 'column2', - `c3` int(11) NOT NULL COMMENT 'column3', - `c4` varchar(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a', - `c5` varchar(255) CHARACTER SET utf8 COLLATE utf8_unicode_ci DEFAULT 'b', - `c6` varchar(255) CHARACTER SET latin1 COLLATE latin1_bin DEFAULT NULL -) ENGINE=MyISAM DEFAULT CHARSET=latin1 - -DROP TABLE t2; -DROP TABLE t1; - -# -- End of test case for Bug#21380. - # -- # -- Bug#18834: ALTER TABLE ADD INDEX on table with two timestamp fields # -- diff --git a/mysql-test/r/have_big5.require b/mysql-test/r/have_big5.require deleted file mode 100644 index 74aacf74b62..00000000000 --- a/mysql-test/r/have_big5.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -big5_chinese_ci big5 1 Yes Yes 1 diff --git a/mysql-test/r/have_cp1250_ch.require b/mysql-test/r/have_cp1250_ch.require deleted file mode 100644 index 2eb834d97e2..00000000000 --- a/mysql-test/r/have_cp1250_ch.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -cp1250_czech_cs cp1250 34 Yes 2 diff --git a/mysql-test/r/have_cp1251.require b/mysql-test/r/have_cp1251.require deleted file mode 100644 index 465e8338084..00000000000 --- a/mysql-test/r/have_cp1251.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -cp1251_general_ci cp1251 51 Yes 0 diff --git a/mysql-test/r/have_cp866.require b/mysql-test/r/have_cp866.require deleted file mode 100644 index da2a3e2f05e..00000000000 --- a/mysql-test/r/have_cp866.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -cp866_general_ci cp866 36 Yes 0 diff --git a/mysql-test/r/have_cp932.require b/mysql-test/r/have_cp932.require deleted file mode 100644 index 988d720ed2c..00000000000 --- a/mysql-test/r/have_cp932.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -cp932_japanese_ci cp932 95 Yes Yes 1 diff --git a/mysql-test/r/have_eucjpms.require b/mysql-test/r/have_eucjpms.require deleted file mode 100644 index f35621b2c1a..00000000000 --- a/mysql-test/r/have_eucjpms.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -eucjpms_japanese_ci eucjpms 97 Yes Yes 1 diff --git a/mysql-test/r/have_euckr.require b/mysql-test/r/have_euckr.require deleted file mode 100644 index 0771ceec570..00000000000 --- a/mysql-test/r/have_euckr.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -euckr_korean_ci euckr 19 Yes Yes 1 diff --git a/mysql-test/r/have_gb2312.require b/mysql-test/r/have_gb2312.require deleted file mode 100644 index 9bcb7c94a14..00000000000 --- a/mysql-test/r/have_gb2312.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -gb2312_chinese_ci gb2312 24 Yes Yes 1 diff --git a/mysql-test/r/have_gbk.require b/mysql-test/r/have_gbk.require deleted file mode 100644 index e19fead153a..00000000000 --- a/mysql-test/r/have_gbk.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -gbk_chinese_ci gbk 28 Yes Yes 1 diff --git a/mysql-test/r/have_koi8r.require b/mysql-test/r/have_koi8r.require deleted file mode 100644 index b109b9ae520..00000000000 --- a/mysql-test/r/have_koi8r.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -koi8r_general_ci koi8r 7 Yes 0 diff --git a/mysql-test/r/have_latin2_ch.require b/mysql-test/r/have_latin2_ch.require deleted file mode 100644 index 352401bbfe8..00000000000 --- a/mysql-test/r/have_latin2_ch.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -latin2_czech_cs latin2 2 Yes 4 diff --git a/mysql-test/r/have_sjis.require b/mysql-test/r/have_sjis.require deleted file mode 100644 index 72ce8ec88fe..00000000000 --- a/mysql-test/r/have_sjis.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -sjis_japanese_ci sjis 13 Yes Yes 1 diff --git a/mysql-test/r/have_tis620.require b/mysql-test/r/have_tis620.require deleted file mode 100644 index a1bf93ac491..00000000000 --- a/mysql-test/r/have_tis620.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -tis620_thai_ci tis620 18 Yes Yes 4 diff --git a/mysql-test/r/have_ucs2.require b/mysql-test/r/have_ucs2.require deleted file mode 100644 index c53250aeaef..00000000000 --- a/mysql-test/r/have_ucs2.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -ucs2_general_ci ucs2 35 Yes Yes 1 diff --git a/mysql-test/r/have_ujis.require b/mysql-test/r/have_ujis.require deleted file mode 100644 index 43a309ad74e..00000000000 --- a/mysql-test/r/have_ujis.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -ujis_japanese_ci ujis 12 Yes Yes 1 diff --git a/mysql-test/r/have_utf8.require b/mysql-test/r/have_utf8.require deleted file mode 100644 index 71f8ccfff47..00000000000 --- a/mysql-test/r/have_utf8.require +++ /dev/null @@ -1,2 +0,0 @@ -Collation Charset Id Default Compiled Sortlen -utf8_general_ci utf8 33 Yes Yes 1 diff --git a/mysql-test/r/innodb.result b/mysql-test/r/innodb.result index 845083af478..021bf34a132 100644 --- a/mysql-test/r/innodb.result +++ b/mysql-test/r/innodb.result @@ -3160,15 +3160,6 @@ ALTER TABLE t2 MODIFY a INT NOT NULL; ERROR HY000: Error on rename of '#sql-temporary' to './test/t2' (errno: 150) DELETE FROM t1; DROP TABLE t2,t1; -CREATE TABLE t1 (a VARCHAR(5) COLLATE utf8_unicode_ci PRIMARY KEY) -ENGINE=InnoDB; -INSERT INTO t1 VALUES (0xEFBCA4EFBCA4EFBCA4); -DELETE FROM t1; -INSERT INTO t1 VALUES ('DDD'); -SELECT * FROM t1; -a -DDD -DROP TABLE t1; CREATE TABLE t1 (id int PRIMARY KEY AUTO_INCREMENT) ENGINE=InnoDB AUTO_INCREMENT=42; INSERT INTO t1 VALUES (0),(347),(0); diff --git a/mysql-test/r/innodb_utf8.result b/mysql-test/r/innodb_utf8.result new file mode 100644 index 00000000000..cdac7cdb65b --- /dev/null +++ b/mysql-test/r/innodb_utf8.result @@ -0,0 +1,10 @@ +drop table if exists t1; +CREATE TABLE t1 (a VARCHAR(5) COLLATE utf8_unicode_ci PRIMARY KEY) +ENGINE=InnoDB; +INSERT INTO t1 VALUES (0xEFBCA4EFBCA4EFBCA4); +DELETE FROM t1; +INSERT INTO t1 VALUES ('DDD'); +SELECT * FROM t1; +a +DDD +DROP TABLE t1; diff --git a/mysql-test/suite/rpl/t/rpl_ignore_table.test b/mysql-test/suite/rpl/t/rpl_ignore_table.test index 66f96e8f4e8..15c4b193669 100644 --- a/mysql-test/suite/rpl/t/rpl_ignore_table.test +++ b/mysql-test/suite/rpl/t/rpl_ignore_table.test @@ -1,4 +1,6 @@ source include/master-slave.inc; +let collation=utf8_unicode_ci; +--source include/have_collation.inc # # BUG#16487 diff --git a/mysql-test/t/create-uca.test b/mysql-test/t/create-uca.test new file mode 100644 index 00000000000..0acb51f7286 --- /dev/null +++ b/mysql-test/t/create-uca.test @@ -0,0 +1,26 @@ +# Prerequisites +let collation=utf8_unicode_ci; +--source include/have_collation.inc + +# Initial cleanup +--disable_warnings +drop table if exists t1,t2; +--enable_warnings + +# +# Bug#21380: DEFAULT definition not always transfered by CREATE +# TABLE/SELECT to the new table. +# + +CREATE TABLE t1( + c1 INT DEFAULT 12 COMMENT 'column1', + c2 INT NULL COMMENT 'column2', + c3 INT NOT NULL COMMENT 'column3', + c4 VARCHAR(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a', + c5 VARCHAR(255) COLLATE utf8_unicode_ci NULL DEFAULT 'b', + c6 VARCHAR(255)) + COLLATE latin1_bin; +SHOW CREATE TABLE t1; +CREATE TABLE t2 AS SELECT * FROM t1; +SHOW CREATE TABLE t2; +DROP TABLE t1,t2; diff --git a/mysql-test/t/create.test b/mysql-test/t/create.test index 885803cb90f..57f4c82df87 100644 --- a/mysql-test/t/create.test +++ b/mysql-test/t/create.test @@ -1398,52 +1398,6 @@ drop table t1; ########################################################################### ---echo ---echo # -- ---echo # -- Bug#21380: DEFAULT definition not always transfered by CREATE ---echo # -- TABLE/SELECT to the new table. ---echo # -- ---echo - - ---disable_warnings -DROP TABLE IF EXISTS t1; -DROP TABLE IF EXISTS t2; ---enable_warnings - ---echo - -CREATE TABLE t1( - c1 INT DEFAULT 12 COMMENT 'column1', - c2 INT NULL COMMENT 'column2', - c3 INT NOT NULL COMMENT 'column3', - c4 VARCHAR(255) CHARACTER SET utf8 NOT NULL DEFAULT 'a', - c5 VARCHAR(255) COLLATE utf8_unicode_ci NULL DEFAULT 'b', - c6 VARCHAR(255)) - COLLATE latin1_bin; - ---echo - -SHOW CREATE TABLE t1; - ---echo - -CREATE TABLE t2 AS SELECT * FROM t1; - ---echo - -SHOW CREATE TABLE t2; - ---echo - -DROP TABLE t2; -DROP TABLE t1; - ---echo ---echo # -- End of test case for Bug#21380. - -########################################################################### - --echo --echo # -- --echo # -- Bug#18834: ALTER TABLE ADD INDEX on table with two timestamp fields diff --git a/mysql-test/t/ctype_utf8.test b/mysql-test/t/ctype_utf8.test index bb64319f1e4..e222bc6b836 100644 --- a/mysql-test/t/ctype_utf8.test +++ b/mysql-test/t/ctype_utf8.test @@ -2,6 +2,15 @@ # Tests with the utf8 character set # +let collation=utf8_unicode_ci; +--source include/have_collation.inc + +--disable_warnings +drop table if exists t1,t2,t3,t4; +drop database if exists mysqltest; +--enable_warnings + + --disable_warnings drop table if exists t1,t2; --enable_warnings diff --git a/mysql-test/t/ddl_i18n_koi8r.test b/mysql-test/t/ddl_i18n_koi8r.test index fecef2f95d5..9df9806526c 100644 --- a/mysql-test/t/ddl_i18n_koi8r.test +++ b/mysql-test/t/ddl_i18n_koi8r.test @@ -36,6 +36,8 @@ --source include/have_cp866.inc --source include/have_cp1251.inc --source include/have_koi8r.inc +let collation=utf8_unicode_ci; +--source include/have_collation.inc ########################################################################### diff --git a/mysql-test/t/ddl_i18n_utf8.test b/mysql-test/t/ddl_i18n_utf8.test index 8788d0604f2..1d8c5676dee 100644 --- a/mysql-test/t/ddl_i18n_utf8.test +++ b/mysql-test/t/ddl_i18n_utf8.test @@ -36,6 +36,8 @@ --source include/have_cp866.inc --source include/have_cp1251.inc --source include/have_koi8r.inc +let collation=utf8_unicode_ci; +--source include/have_collation.inc ########################################################################### diff --git a/mysql-test/t/fulltext.test b/mysql-test/t/fulltext.test index 9db55f6adaa..766e6d12cf4 100644 --- a/mysql-test/t/fulltext.test +++ b/mysql-test/t/fulltext.test @@ -2,6 +2,9 @@ # Test of fulltext index # +let collation=utf8_unicode_ci; +--source include/have_collation.inc + --disable_warnings drop table if exists t1,t2,t3; --enable_warnings diff --git a/mysql-test/t/fulltext2.test b/mysql-test/t/fulltext2.test index 9635e14d427..78c7c859e95 100644 --- a/mysql-test/t/fulltext2.test +++ b/mysql-test/t/fulltext2.test @@ -2,6 +2,9 @@ # test of new fulltext search features # +let collation=utf8_unicode_ci; +--source include/have_collation.inc + # # two-level tree # diff --git a/mysql-test/t/innodb.test b/mysql-test/t/innodb.test index 6eb32b554bb..599c6f10d23 100644 --- a/mysql-test/t/innodb.test +++ b/mysql-test/t/innodb.test @@ -2352,18 +2352,6 @@ ALTER TABLE t2 MODIFY a INT NOT NULL; DELETE FROM t1; DROP TABLE t2,t1; -# -# Bug #26835: table corruption after delete+insert -# - -CREATE TABLE t1 (a VARCHAR(5) COLLATE utf8_unicode_ci PRIMARY KEY) -ENGINE=InnoDB; -INSERT INTO t1 VALUES (0xEFBCA4EFBCA4EFBCA4); -DELETE FROM t1; -INSERT INTO t1 VALUES ('DDD'); -SELECT * FROM t1; -DROP TABLE t1; - # # Bug #23313 (AUTO_INCREMENT=# not reported back for InnoDB tables) # Bug #21404 (AUTO_INCREMENT value reset when Adding FKEY (or ALTER?)) diff --git a/mysql-test/t/innodb_utf8.test b/mysql-test/t/innodb_utf8.test new file mode 100644 index 00000000000..e52019588b0 --- /dev/null +++ b/mysql-test/t/innodb_utf8.test @@ -0,0 +1,24 @@ +# +# Tests for innodb that requires not default character sets +# + +--source include/have_innodb.inc +let collation=utf8_unicode_ci; +--source include/have_collation.inc + +# Setup +--disable_warnings +drop table if exists t1; +--enable_warnings + +# +# Bug #26835: table corruption after delete+insert +# + +CREATE TABLE t1 (a VARCHAR(5) COLLATE utf8_unicode_ci PRIMARY KEY) +ENGINE=InnoDB; +INSERT INTO t1 VALUES (0xEFBCA4EFBCA4EFBCA4); +DELETE FROM t1; +INSERT INTO t1 VALUES ('DDD'); +SELECT * FROM t1; +DROP TABLE t1; diff --git a/mysql-test/t/query_cache_ps_no_prot.test b/mysql-test/t/query_cache_ps_no_prot.test index 6f4263eeef9..16533c7194e 100644 --- a/mysql-test/t/query_cache_ps_no_prot.test +++ b/mysql-test/t/query_cache_ps_no_prot.test @@ -11,8 +11,9 @@ # We cannot run on embedded server because we use multiple sessions. --source include/not_embedded.inc - --source include/have_query_cache.inc +let collation=utf8_unicode_ci; +--source include/have_collation.inc # The file with expected results fits only to a run without # ps-protocol/sp-protocol/cursor-protocol/view-protocol. diff --git a/mysql-test/t/query_cache_ps_ps_prot.test b/mysql-test/t/query_cache_ps_ps_prot.test index dc49624788a..d431ce349d2 100644 --- a/mysql-test/t/query_cache_ps_ps_prot.test +++ b/mysql-test/t/query_cache_ps_ps_prot.test @@ -11,8 +11,9 @@ # We cannot run on embedded server because we use multiple sessions. --source include/not_embedded.inc - --source include/have_query_cache.inc +let collation=utf8_unicode_ci; +--source include/have_collation.inc # The file with expected results fits only to a run with "--ps-protocol". if (`SELECT $SP_PROTOCOL + $CURSOR_PROTOCOL + $VIEW_PROTOCOL > 0 diff --git a/scripts/mysqlbug.sh b/scripts/mysqlbug.sh index 64804b5de19..f0534d0e1e9 100644 --- a/scripts/mysqlbug.sh +++ b/scripts/mysqlbug.sh @@ -21,7 +21,7 @@ echo "Finding system information for a MySQL bug report" VERSION="@VERSION@@MYSQL_SERVER_SUFFIX@" COMPILATION_COMMENT="@COMPILATION_COMMENT@" -BUGmysql="mysql@lists.mysql.com" +BUGmysql="maria-developers@lists.launchpad.net" # This is set by configure COMP_CALL_INFO="CC='@SAVE_CC@' CFLAGS='@SAVE_CFLAGS@' CXX='@SAVE_CXX@' CXXFLAGS='@SAVE_CXXFLAGS@' LDFLAGS='@SAVE_LDFLAGS@' ASFLAGS='@SAVE_ASFLAGS@'" COMP_RUN_INFO="CC='@CC@' CFLAGS='@CFLAGS@' CXX='@CXX@' CXXFLAGS='@CXXFLAGS@' LDFLAGS='@LDFLAGS@' ASFLAGS='@ASFLAGS@'" diff --git a/storage/ndb/plug.in b/storage/ndb/plug.in index a7e351417b1..3d3349f7a8b 100644 --- a/storage/ndb/plug.in +++ b/storage/ndb/plug.in @@ -1,5 +1,5 @@ MYSQL_STORAGE_ENGINE(ndbcluster, ndbcluster, [Cluster Storage Engine], - [High Availability Clustered tables], [max]) + [High Availability Clustered tables],) MYSQL_PLUGIN_DIRECTORY(ndbcluster,[storage/ndb]) MYSQL_PLUGIN_STATIC(ndbcluster, [[\$(ndbcluster_libs) \$(ndbcluster_system_libs) \$(NDB_SCI_LIBS)]]) MYSQL_PLUGIN_ACTIONS(ndbcluster,[MYSQL_SETUP_NDBCLUSTER]) From 7ae95fdef2b5d4880d381d6ed46ad4aa996b03d3 Mon Sep 17 00:00:00 2001 From: Michael Widenius Date: Mon, 4 Jan 2010 14:35:54 +0200 Subject: [PATCH 3/5] Updated test results (missed this one in last patch) --- mysql-test/r/ctype_utf8.result | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mysql-test/r/ctype_utf8.result b/mysql-test/r/ctype_utf8.result index 4cfd06149f1..b3084d182a6 100644 --- a/mysql-test/r/ctype_utf8.result +++ b/mysql-test/r/ctype_utf8.result @@ -1,3 +1,5 @@ +drop table if exists t1,t2,t3,t4; +drop database if exists mysqltest; drop table if exists t1,t2; set names utf8; select left(_utf8 0xD0B0D0B1D0B2,1); From fa609710375a68c244179e58e53b2980387a84d0 Mon Sep 17 00:00:00 2001 From: Michael Widenius Date: Mon, 4 Jan 2010 20:25:29 +0200 Subject: [PATCH 4/5] Fixed bug in tc.log recovery code that caused crash_commit_before to sometimes crash. --- sql/log.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sql/log.cc b/sql/log.cc index 9ed594bfb36..6d1a8bf47a8 100644 --- a/sql/log.cc +++ b/sql/log.cc @@ -5154,8 +5154,8 @@ int TC_LOG_MMAP::open(const char *opt_name) pthread_mutex_init(&pg->lock, MY_MUTEX_INIT_FAST); pthread_cond_init (&pg->cond, 0); pg->start=(my_xid *)(data + i*tc_log_page_size); - pg->end=(my_xid *)(pg->start + tc_log_page_size); pg->size=pg->free=tc_log_page_size/sizeof(my_xid); + pg->end=pg->start + pg->size; } pages[0].size=pages[0].free= (tc_log_page_size-TC_LOG_HEADER_SIZE)/sizeof(my_xid); From ce068186f698872e6d7c7f475ffa2bca664f070d Mon Sep 17 00:00:00 2001 From: Michael Widenius Date: Mon, 4 Jan 2010 20:31:26 +0200 Subject: [PATCH 5/5] Fixed bug in my_uuid() that caused failures on hpux and ia64 --- mysys/my_uuid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mysys/my_uuid.c b/mysys/my_uuid.c index d1e8331aaa1..f115806b4e9 100644 --- a/mysys/my_uuid.c +++ b/mysys/my_uuid.c @@ -108,7 +108,7 @@ void my_uuid_init(ulong seed1, ulong seed2) */ /* purecov: begin inspected */ my_rnd_init(&uuid_rand, (ulong) (seed2+ now/2), (ulong) (now+rand())); - for (i=0; i < sizeof(mac); i++) + for (i=0; i < array_elements(uuid_suffix) -2 ; i++) mac[i]= (uchar)(my_rnd(&uuid_rand)*255); /* purecov: end */ }