diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2021-03-03 09:41:50 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2021-03-03 09:41:50 +0200 |
commit | ddbc6126920c1ad0300f7f9734348309f5073de7 (patch) | |
tree | f98a56b0fef476345979f3a228de8ffd27da0ea6 /mysql-test/main/set_statement.result | |
parent | 0f81ca6a0bb21fbba4bca93a7555f7c8e6357b47 (diff) | |
parent | 676987c4a14069d415c56d0f259aaaa7ca742c23 (diff) | |
download | mariadb-git-ddbc6126920c1ad0300f7f9734348309f5073de7.tar.gz |
Merge 10.2 into 10.3
Diffstat (limited to 'mysql-test/main/set_statement.result')
-rw-r--r-- | mysql-test/main/set_statement.result | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/mysql-test/main/set_statement.result b/mysql-test/main/set_statement.result index 48675145fd2..76f943edfc6 100644 --- a/mysql-test/main/set_statement.result +++ b/mysql-test/main/set_statement.result @@ -1217,3 +1217,28 @@ set @rnd=1; select @rnd; @rnd 0 +# +# MDEV-24860: Incorrect behaviour of SET STATEMENT in case +# it is executed as a prepared statement +# +PREPARE stmt FROM "SET STATEMENT sql_mode = 'NO_ENGINE_SUBSTITUTION' FOR CREATE TABLE t1 AS SELECT CONCAT('abc') AS c1"; +EXECUTE stmt; +DEALLOCATE PREPARE stmt; +# Show definition of the table t1 created using Prepared Statement +SHOW CREATE TABLE t1; +Table Create Table +t1 CREATE TABLE `t1` ( + `c1` varchar(3) NOT NULL +) ENGINE=MyISAM DEFAULT CHARSET=latin1 +DROP TABLE t1; +# Create the table t1 with the same definition as it used before +# using regular statement execution mode. +SET STATEMENT sql_mode = 'NO_ENGINE_SUBSTITUTION' FOR CREATE TABLE t1 AS SELECT CONCAT('abc') AS c1; +# Show that the table has the same definition as it is in case the table +# created in prepared statement mode. +SHOW CREATE TABLE t1; +Table Create Table +t1 CREATE TABLE `t1` ( + `c1` varchar(3) NOT NULL +) ENGINE=MyISAM DEFAULT CHARSET=latin1 +DROP TABLE t1; |