summaryrefslogtreecommitdiff
path: root/mysql-test/t/func_json.test
diff options
context:
space:
mode:
authorAlexey Botchkov <holyfoot@askmonty.org>2017-05-02 15:16:01 +0400
committerAlexey Botchkov <holyfoot@askmonty.org>2017-05-02 15:16:01 +0400
commit4a484e7a207f927089893a0344afa15031803e5d (patch)
tree3a185aa2e7328f78e39dac60566e150ceb04fad4 /mysql-test/t/func_json.test
parent42ad4f2821112be4e7bb4ca6d407cc72f9df6f8d (diff)
downloadmariadb-git-4a484e7a207f927089893a0344afa15031803e5d.tar.gz
MDEV-12351 Assertion `cur_step->type & JSON_PATH_KEY' failed in
json_find_path. The ..[0] path can be treated wrong on second json_find_path call.
Diffstat (limited to 'mysql-test/t/func_json.test')
-rw-r--r--mysql-test/t/func_json.test6
1 files changed, 6 insertions, 0 deletions
diff --git a/mysql-test/t/func_json.test b/mysql-test/t/func_json.test
index 7ff5f3f13d9..ce13456bf25 100644
--- a/mysql-test/t/func_json.test
+++ b/mysql-test/t/func_json.test
@@ -281,3 +281,9 @@ drop table t1;
SET @str = 'bar', @path = '$';
SELECT JSON_SEARCH('{"foo":"bar"}', 'all' , @str, '%', @path);
+#
+# MDEV-12351 Assertion `cur_step->type & JSON_PATH_KEY' failed in json_find_path.
+#
+
+SELECT JSON_VALUE('[{"foo": 1},"bar"]', '$[*][0]');
+