This commit is contained in:
kssenii 2021-03-30 12:22:54 +00:00 committed by Peng Jian
parent 4daf011e0b
commit bbb8a44399
2 changed files with 15 additions and 0 deletions

View File

@ -13,3 +13,10 @@ test"string
"["
["]", "2", "3"]
{"nested" : [1,2,3]}
-1
0
0
-1
1
test_string
test"string

View File

@ -15,3 +15,11 @@ SELECT visitParamExtractRaw('{"myparam": "{"}', 'myparam');
SELECT visitParamExtractRaw('{"myparam": "["}', 'myparam');
SELECT visitParamExtractRaw('{"myparam": ["]", "2", "3"], "other":123}', 'myparam');
SELECT visitParamExtractRaw('{"myparam": {"nested" : [1,2,3]}, "other":123}', 'myparam');
SELECT JSONExtractInt('{"myparam":-1}', 'myparam');
SELECT JSONExtractUInt('{"myparam":-1}', 'myparam');
SELECT JSONExtractFloat('{"myparam":null}', 'myparam');
SELECT JSONExtractFloat('{"myparam":-1}', 'myparam');
SELECT JSONExtractBool('{"myparam":true}', 'myparam');
SELECT JSONExtractString('{"myparam":"test_string"}', 'myparam');
SELECT JSONExtractString('{"myparam":"test\\"string"}', 'myparam');