By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
Help with an interesting Postgres question: Why isn't an Index Only Scan used on a partition accessed via the parent table?.
select *
from jsonb_path_query('[{"foo":1},{"foo":2}]'::jsonb,'$'::jsonpath)
jsonb_path_query |
---|
[{"foo": 1}, {"foo": 2}] |
select *
from jsonb_path_query_array('[{"foo":1},{"foo":2}]'::jsonb,'$'::jsonpath)
jsonb_path_query_array |
---|
[[{"foo": 1}, {"foo": 2}]] |
select *
from jsonb_array_elements(
jsonb_path_query(
'[{"foo":1},{"foo":2}]'::jsonb,
'$'::jsonpath
)
)
ERROR: set-returning functions must appear at top level of FROM
LINE 3: jsonb_path_query(
^