diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2021-05-25 15:38:57 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2021-05-25 15:38:57 +0300 |
commit | 1dea7f79779d13695876b84ebecbf41c13d845cb (patch) | |
tree | fec8bf2607e69a9c6069001bb0de1f33fcae46ba /mysql-test/main | |
parent | 04de651725c3eeee8f216c55e2f8133e4547fadb (diff) | |
parent | 1864a8ea93aa1d1a540c83526a25df2ad0330763 (diff) | |
download | mariadb-git-1dea7f79779d13695876b84ebecbf41c13d845cb.tar.gz |
Merge 10.3 into 10.4
Diffstat (limited to 'mysql-test/main')
-rw-r--r-- | mysql-test/main/ctype_filename.result | 33 | ||||
-rw-r--r-- | mysql-test/main/ctype_filename.test | 28 | ||||
-rw-r--r-- | mysql-test/main/mysqld--help.result | 2 | ||||
-rw-r--r-- | mysql-test/main/mysqld--help.test | 2 | ||||
-rw-r--r-- | mysql-test/main/subselect4.result | 21 | ||||
-rw-r--r-- | mysql-test/main/subselect4.test | 27 |
6 files changed, 108 insertions, 5 deletions
diff --git a/mysql-test/main/ctype_filename.result b/mysql-test/main/ctype_filename.result index 7536ea97fb1..955e1ff8a8f 100644 --- a/mysql-test/main/ctype_filename.result +++ b/mysql-test/main/ctype_filename.result @@ -22,9 +22,40 @@ SELECT @a:=CONVERT('aя' USING filename) AS `@a`, BINARY @a, REVERSE(@a), HEX(@a @a BINARY @a REVERSE(@a) HEX(@a) HEX(REVERSE(@a)) aя a@r1 яa 61407231 40723161 # +# Beginning of 10.2 test. +# +# MDEV-25462: Assertion `m_status == DA_ERROR || m_status == DA_OK || +# m_status == DA_OK_BULK' failed in Diagnostics_area::message from +# get_schema_tables_record +# +SELECT @@character_set_client, @@character_set_connection, @@character_set_results; +@@character_set_client @@character_set_connection @@character_set_results +utf8 utf8 utf8 +SET @old_character_set_client= @@character_set_client; +SET @old_character_set_connection= @@character_set_connection; +SET @old_character_set_results= @@character_set_results; +SET NAMES 'filename'; +ERROR 42000: Variable 'character_set_client' can't be set to the value of 'filename' +SELECT @@character_set_client, @@character_set_connection, @@character_set_results; +@@character_set_client @@character_set_connection @@character_set_results +utf8 utf8 utf8 +CREATE VIEW v2 AS SELECT 1; +SHOW TABLE STATUS; +Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment Max_index_length Temporary +v2 NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL NULL VIEW NULL NULL +DROP VIEW v2; +SET @@character_set_client= @old_character_set_client; +SET @@character_set_connection= @old_character_set_connection; +SET @@character_set_results= @old_character_set_results; +# +# End of 10.2 test +# +# # MDEV-22022 Various mangled SQL statements will crash 10.3 to 10.5 debug builds # SET CHARACTER_SET_CLIENT=17; +ERROR 42000: Variable 'character_set_client' can't be set to the value of '17' SELECT doc.`Children`.0 FROM t1; -ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '?Children??0?FROM?t1' at line 1 +ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '.0 FROM t1' at line 1 SET NAMES latin1; +# End of 10.3 tests diff --git a/mysql-test/main/ctype_filename.test b/mysql-test/main/ctype_filename.test index 6f77a6c5a3a..0c38172a0ef 100644 --- a/mysql-test/main/ctype_filename.test +++ b/mysql-test/main/ctype_filename.test @@ -28,12 +28,40 @@ select convert(convert(',' using filename) using binary); SET NAMES utf8; SELECT @a:=CONVERT('aя' USING filename) AS `@a`, BINARY @a, REVERSE(@a), HEX(@a), HEX(REVERSE(@a)); +--echo # +--echo # Beginning of 10.2 test. +--echo # +--echo # MDEV-25462: Assertion `m_status == DA_ERROR || m_status == DA_OK || +--echo # m_status == DA_OK_BULK' failed in Diagnostics_area::message from +--echo # get_schema_tables_record +--echo # + +SELECT @@character_set_client, @@character_set_connection, @@character_set_results; +SET @old_character_set_client= @@character_set_client; +SET @old_character_set_connection= @@character_set_connection; +SET @old_character_set_results= @@character_set_results; +--error ER_WRONG_VALUE_FOR_VAR +SET NAMES 'filename'; +SELECT @@character_set_client, @@character_set_connection, @@character_set_results; +CREATE VIEW v2 AS SELECT 1; +SHOW TABLE STATUS; +DROP VIEW v2; +SET @@character_set_client= @old_character_set_client; +SET @@character_set_connection= @old_character_set_connection; +SET @@character_set_results= @old_character_set_results; + +--echo # +--echo # End of 10.2 test +--echo # --echo # --echo # MDEV-22022 Various mangled SQL statements will crash 10.3 to 10.5 debug builds --echo # +--error ER_WRONG_VALUE_FOR_VAR SET CHARACTER_SET_CLIENT=17; --error ER_PARSE_ERROR SELECT doc.`Children`.0 FROM t1; SET NAMES latin1; + +--echo # End of 10.3 tests diff --git a/mysql-test/main/mysqld--help.result b/mysql-test/main/mysqld--help.result index 45b1e4afe05..c008df32257 100644 --- a/mysql-test/main/mysqld--help.result +++ b/mysql-test/main/mysqld--help.result @@ -1519,7 +1519,7 @@ lc-messages-dir MYSQL_SHAREDIR/ lc-time-names en_US local-infile TRUE lock-wait-timeout 86400 -log-bin (No default value) +log-bin foo log-bin-compress FALSE log-bin-compress-min-len 256 log-bin-index (No default value) diff --git a/mysql-test/main/mysqld--help.test b/mysql-test/main/mysqld--help.test index 6fff3f51006..b54af092a5e 100644 --- a/mysql-test/main/mysqld--help.test +++ b/mysql-test/main/mysqld--help.test @@ -13,7 +13,7 @@ # force symbolic-links=0 (valgrind build has a different default) # -exec $MYSQLD_BOOTSTRAP_CMD --symbolic-links=0 --lower-case-table-names=1 --help --verbose > $MYSQL_TMP_DIR/mysqld--help.txt 2>&1; +exec $MYSQLD_BOOTSTRAP_CMD --symbolic-links=0 --log-bin=foo --lower-case-table-names=1 --help --verbose > $MYSQL_TMP_DIR/mysqld--help.txt 2>&1; # The inline perl code below will copy $MYSQL_TMP_DIR/mysqld--help.txt # to output, but filter away some variable stuff (e.g. paths). diff --git a/mysql-test/main/subselect4.result b/mysql-test/main/subselect4.result index 4452c456022..e4e9a5c8917 100644 --- a/mysql-test/main/subselect4.result +++ b/mysql-test/main/subselect4.result @@ -2721,7 +2721,15 @@ id select_type table type possible_keys key key_len ref rows Extra SELECT a FROM t1 WHERE (a, a) IN (SELECT 1, 2) AND a = (SELECT MIN(b) FROM t2); a DROP TABLE t1,t2; -# End of 10.2 tests +# +# MDEV-22462: Item_in_subselect::create_single_in_to_exists_cond(JOIN *, Item **, Item **): Assertion `false' failed. +# +select 1 from dual where 1 in (select 5 from dual where 1); +1 +create table t1 (a int); +insert into t1 values (1),(2),(3); +update t1 set a = 2 where a in (select a from dual where a = a); +drop table t1; # # MDEV-18335: Assertion `!error || error == 137' failed in subselect_rowid_merge_engine::init # @@ -2847,6 +2855,17 @@ INSERT INTO t2 VALUES (3),(4); SELECT 1 IN (SELECT (SELECT a FROM t1) AS x FROM t2 GROUP BY x); ERROR 21000: Subquery returns more than 1 row drop table t1,t2; +# +# MDEV-25629: Crash in get_sort_by_table() in subquery with order by having outer ref +# +CREATE TABLE t1 (i1 int); +insert into t1 values (1),(2); +SELECT 1 +FROM (t1 JOIN t1 AS ref_t1 ON +(t1.i1 > (SELECT ref_t1.i1 AS c0 FROM t1 b ORDER BY -c0))); +ERROR 21000: Subquery returns more than 1 row +DROP TABLE t1; +# End of 10.2 tests # End of 10.3 tests # # MDEV-19134: EXISTS() slower if ORDER BY is defined diff --git a/mysql-test/main/subselect4.test b/mysql-test/main/subselect4.test index a2dfc48ffe2..329a6726a6b 100644 --- a/mysql-test/main/subselect4.test +++ b/mysql-test/main/subselect4.test @@ -2236,7 +2236,17 @@ SELECT a FROM t1 WHERE (a, a) IN (SELECT 1, 2) AND a = (SELECT MIN(b) FROM t2); DROP TABLE t1,t2; ---echo # End of 10.2 tests +--echo # +--echo # MDEV-22462: Item_in_subselect::create_single_in_to_exists_cond(JOIN *, Item **, Item **): Assertion `false' failed. +--echo # + +select 1 from dual where 1 in (select 5 from dual where 1); + +create table t1 (a int); +insert into t1 values (1),(2),(3); + +update t1 set a = 2 where a in (select a from dual where a = a); +drop table t1; --echo # --echo # MDEV-18335: Assertion `!error || error == 137' failed in subselect_rowid_merge_engine::init @@ -2353,6 +2363,21 @@ INSERT INTO t2 VALUES (3),(4); # Optional, fails either way SELECT 1 IN (SELECT (SELECT a FROM t1) AS x FROM t2 GROUP BY x); drop table t1,t2; +--echo # +--echo # MDEV-25629: Crash in get_sort_by_table() in subquery with order by having outer ref +--echo # +CREATE TABLE t1 (i1 int); +insert into t1 values (1),(2); + +--error ER_SUBQUERY_NO_1_ROW +SELECT 1 +FROM (t1 JOIN t1 AS ref_t1 ON + (t1.i1 > (SELECT ref_t1.i1 AS c0 FROM t1 b ORDER BY -c0))); + +DROP TABLE t1; + +--echo # End of 10.2 tests + --echo # End of 10.3 tests --echo # |