Re: json accessors

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: json accessors
Date: 2012-12-04 01:14:24
Message-ID: 50BD4E70.4090006@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andrew,

What about doing:

json_get(json, json)
returns json

where parameter #2 is a path expressed as JSON? For example,

json_get(personal_profile, '[ {contact_info {phone numbers {cell phones}
} } ]')
... would return whatever was in that heirarchical object, in this case
an array of cell phone numbers.

Or am I just reinventing jsonpath?

--
Josh Berkus
PostgreSQL Experts Inc.
http://pgexperts.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jeff Davis 2012-12-04 01:34:01 Commits 8de72b and 5457a1 (COPY FREEZE)
Previous Message Andrew Dunstan 2012-12-04 00:17:36 Re: [COMMITTERS] pgsql: Add mode where contrib installcheck runs each module in a separa