Skip to content

Commit

Permalink
[CH-419] support map type for JSONExtract and fix bugs for explode/po…
Browse files Browse the repository at this point in the history
…sexplode (#421)
  • Loading branch information
taiyang-li authored Apr 13, 2023
1 parent ddf2f50 commit ea6d8dd
Show file tree
Hide file tree
Showing 6 changed files with 1,755 additions and 1,661 deletions.
1 change: 1 addition & 0 deletions docs/en/sql-reference/functions/json-functions.md
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,7 @@ Examples:
``` sql
SELECT JSONExtract('{"a": "hello", "b": [-100, 200.0, 300]}', 'Tuple(String, Array(Float64))') = ('hello',[-100,200,300])
SELECT JSONExtract('{"a": "hello", "b": [-100, 200.0, 300]}', 'Tuple(b Array(Float64), a String)') = ([-100,200,300],'hello')
SELECT JSONExtract('{"a": "hello", "b": "world"}', 'Map(String, String)') = map('a', 'hello', 'b', 'world');
SELECT JSONExtract('{"a": "hello", "b": [-100, 200.0, 300]}', 'b', 'Array(Nullable(Int8))') = [-100, NULL, NULL]
SELECT JSONExtract('{"a": "hello", "b": [-100, 200.0, 300]}', 'b', 4, 'Nullable(Int64)') = NULL
SELECT JSONExtract('{"passed": true}', 'passed', 'UInt8') = 1
Expand Down
Loading

0 comments on commit ea6d8dd

Please sign in to comment.