summaryrefslogtreecommitdiff
path: root/mysql-test/suite/json
diff options
context:
space:
mode:
authorOleksandr Byelkin <sanja@mariadb.com>2022-10-16 21:40:33 +0200
committerOleksandr Byelkin <sanja@mariadb.com>2022-10-16 21:40:33 +0200
commitec2b30e7367fcd4b2af0d7ae42d7b83148a859a4 (patch)
treea74c8446a01f1dbd785d8c268e97698952711a67 /mysql-test/suite/json
parent8a9e17103bb6c111882fa6ec589e4fed4f07d389 (diff)
parent822694bd56a74eb4a81a85db683fe7b0837029ed (diff)
downloadmariadb-git-ec2b30e7367fcd4b2af0d7ae42d7b83148a859a4.tar.gz
Merge branch '10.6' into 10.7
Diffstat (limited to 'mysql-test/suite/json')
-rw-r--r--mysql-test/suite/json/r/json_table.result6
-rw-r--r--mysql-test/suite/json/t/json_table.test8
2 files changed, 14 insertions, 0 deletions
diff --git a/mysql-test/suite/json/r/json_table.result b/mysql-test/suite/json/r/json_table.result
index cc87a34ffb3..b9cc09fdd97 100644
--- a/mysql-test/suite/json/r/json_table.result
+++ b/mysql-test/suite/json/r/json_table.result
@@ -1005,5 +1005,11 @@ name VARCHAR(10) CHARACTER SET latin1 COLLATE DEFAULT PATH '$.name'
name
Jeans
#
+# MDEV-28480: Assertion `0' failed in Item_row::illegal_method_call
+# on SELECT FROM JSON_TABLE
+#
+SELECT 1 FROM JSON_TABLE (row(1,2), '$' COLUMNS (o FOR ORDINALITY)) AS j;
+ERROR 21000: Operand should contain 1 column(s)
+#
# End of 10.6 tests
#
diff --git a/mysql-test/suite/json/t/json_table.test b/mysql-test/suite/json/t/json_table.test
index a6392b7bfff..ec330046f25 100644
--- a/mysql-test/suite/json/t/json_table.test
+++ b/mysql-test/suite/json/t/json_table.test
@@ -864,5 +864,13 @@ SELECT * FROM json_table('[{"name":"Jeans"}]', '$[*]'
--echo #
+--echo # MDEV-28480: Assertion `0' failed in Item_row::illegal_method_call
+--echo # on SELECT FROM JSON_TABLE
+--echo #
+
+--error ER_OPERAND_COLUMNS
+SELECT 1 FROM JSON_TABLE (row(1,2), '$' COLUMNS (o FOR ORDINALITY)) AS j;
+
+--echo #
--echo # End of 10.6 tests
--echo #