Re: jsonb_array_elements_recursive() - Mailing list pgsql-hackers

From Joel Jacobson
Subject Re: jsonb_array_elements_recursive()
Date
Msg-id 82309d63-eb84-4bb7-a387-e76e8ca265fd@www.fastmail.com
Whole thread Raw
In response to jsonb_array_elements_recursive()  ("Joel Jacobson" <joel@compiler.org>)
Responses Re: jsonb_array_elements_recursive()
Re: jsonb_array_elements_recursive()
List pgsql-hackers
Having thought about this some more,
the function name should of course be jsonb_unnest(),
similar to how unnest() works for normal arrays:

SELECT unnest(array[[3,2],[1,4]]);
unnest
--------
      3
      2
      1
      4
(4 rows)

SELECT jsonb_unnest('[[3,2],[1,4]]'::jsonb);
jsonb_unnest
--------------------
3
2
1
4
(4 rows)

Thoughts?

pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Prevent printing "next step instructions" in initdb and pg_upgrade
Next
From: Pavel Stehule
Date:
Subject: Re: jsonb_array_elements_recursive()