1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

MDEV-11437 JSON_QUOTE function does not quote and uses wrong character set.

json_quote fixed.
This commit is contained in:
Alexey Botchkov
2016-12-04 14:49:06 +04:00
parent b4cbaf0b7c
commit 12897a5bba
3 changed files with 23 additions and 6 deletions

View File

@ -186,7 +186,17 @@ json_exists('{"key1":"xxxx", "key2":[1, 2, 3]}', "$.key2[10]")
0
select json_quote('"string"');
json_quote('"string"')
\"string\"
"\"string\""
create table t1 as select json_quote('foo');
select * from t1;
json_quote('foo')
"foo"
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`json_quote('foo')` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
select json_merge('string', 123);
json_merge('string', 123)
["string", 123]