summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mariadb.com>2022-10-24 13:58:14 +0400
committerAlexander Barkov <bar@mariadb.com>2022-10-24 13:58:14 +0400
commit28d6f6a514366d0358a7215dc7ef202e2b758c10 (patch)
tree7228ad3fb16ae05b3e9d80ed2034c8402e783316
parent68fb05c360897112fe14038beffff7937d4337e6 (diff)
downloadmariadb-git-28d6f6a514366d0358a7215dc7ef202e2b758c10.tar.gz
MDEV-14983 Wrong error message with SET sql_mode=sha2(ucs2_value)
The problem was fixed earlier. Adding an MTR test only.
-rw-r--r--mysql-test/main/ctype_ucs.result11
-rw-r--r--mysql-test/main/ctype_ucs.test15
2 files changed, 26 insertions, 0 deletions
diff --git a/mysql-test/main/ctype_ucs.result b/mysql-test/main/ctype_ucs.result
index 7682134ea27..3cdb1c7968c 100644
--- a/mysql-test/main/ctype_ucs.result
+++ b/mysql-test/main/ctype_ucs.result
@@ -6391,3 +6391,14 @@ DEALLOCATE PREPARE stmt;
#
# End of 10.2 tests
#
+#
+# Start of 10.3 tests
+#
+#
+# MDEV-14983 Wrong error message with SET sql_mode=sha2(ucs2_value)
+#
+SET sql_mode=sha2(CONVERT('a' USING ucs2),0);
+ERROR 42000: Variable 'sql_mode' can't be set to the value of '022a6979e6dab7aa5ae4c3e5e45f7e977112a7e63593820dbec1ec738a24f93c'
+#
+# End of 10.3 tests
+#
diff --git a/mysql-test/main/ctype_ucs.test b/mysql-test/main/ctype_ucs.test
index d0d463c0340..00eade52a5a 100644
--- a/mysql-test/main/ctype_ucs.test
+++ b/mysql-test/main/ctype_ucs.test
@@ -1094,3 +1094,18 @@ DEALLOCATE PREPARE stmt;
--echo #
--echo # End of 10.2 tests
--echo #
+
+--echo #
+--echo # Start of 10.3 tests
+--echo #
+
+--echo #
+--echo # MDEV-14983 Wrong error message with SET sql_mode=sha2(ucs2_value)
+--echo #
+
+--error ER_WRONG_VALUE_FOR_VAR
+SET sql_mode=sha2(CONVERT('a' USING ucs2),0);
+
+--echo #
+--echo # End of 10.3 tests
+--echo #