Skip to content

Commit daa867b

Browse files
committed
patterns
1 parent 1c9872f commit daa867b

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

Patterns JSON and DSV Output.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ WITH
6666
SELECT
6767
json_group_array(json_object('bin_id', bin_id, 'prefix', prefix, 'name', name)) AS fs_objects
6868
FROM folders
69-
)
69+
)
7070
SELECT * FROM json_fs_objects;
7171
~~~
7272

@@ -80,7 +80,7 @@ return a scalar string containing a set of records in the JSON format:
8080
]
8181
~~~
8282

83-
JSON objects are a bit too verbous when returning a record set, but there are a few other options. For example:
83+
JSON objects are a bit too verbose when returning a record set, but there are a few other options. For example:
8484

8585
~~~sql
8686
WITH

Patterns SQL Interface - JSON Input.md

+2
Original file line numberDiff line numberDiff line change
@@ -174,4 +174,6 @@ WITH
174174
SELECT * FROM folders;
175175
~~~
176176

177+
It is worth mentioning that the *array of objects* construct is a bit verbose. The alternative option is using *array of arrays* with mostly identical code. The downside of using this somewhat more efficient format is the increased risk of subtle bugs; switching to it is probably only justified when there is a demonstrated significant overall performance benefit.
178+
177179
---

0 commit comments

Comments
 (0)