mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
MDEV-11441 Server crashes in String::append /Item_func_json_extract::val_str.
Wrong 'value_lengh' taken
This commit is contained in:
@ -90,7 +90,7 @@ json_contains_path('{"key1":1, "key2":[2,3]}', "aLl", "$.key1", "$.key2")
|
||||
1
|
||||
select json_extract('{"key1":"asd", "key2":[2,3]}', "$.key1");
|
||||
json_extract('{"key1":"asd", "key2":[2,3]}', "$.key1")
|
||||
asd
|
||||
"asd"
|
||||
select json_extract('{"key1":"asd", "key2":[2,3]}', "$.keyX", "$.keyY");
|
||||
json_extract('{"key1":"asd", "key2":[2,3]}', "$.keyX", "$.keyY")
|
||||
NULL
|
||||
@ -102,7 +102,10 @@ json_extract('{"key1":5, "key2":[2,3]}', "$.key1", "$.key2")
|
||||
[5, [2,3]]
|
||||
select json_extract('{"key0":true, "key1":"qwe"}', "$.key1");
|
||||
json_extract('{"key0":true, "key1":"qwe"}', "$.key1")
|
||||
qwe
|
||||
"qwe"
|
||||
select json_extract(json_object('foo', 'foobar'),'$');
|
||||
json_extract(json_object('foo', 'foobar'),'$')
|
||||
{"foo": "foobar"}
|
||||
select json_insert('{"a":1, "b":{"c":1}, "d":[1, 2]}', '$.b.k1', 'word');
|
||||
json_insert('{"a":1, "b":{"c":1}, "d":[1, 2]}', '$.b.k1', 'word')
|
||||
{"a":1, "b":{"c":1, "k1":"word"}, "d":[1, 2]}
|
||||
|
Reference in New Issue
Block a user