Re: BUG #14364: json_populate_record doesn't accept JSON arrays

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: joerg(at)bec(dot)de
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #14364: json_populate_record doesn't accept JSON arrays
Date: 2016-10-13 20:19:26
Message-ID: 29672.1476389966@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

joerg(at)bec(dot)de writes:
> json_populate_record expects arrays in fields using the PG array literal
> syntax, it doesn't support JSON arrays. This is highly annoying as the JSON
> output functions like row_to_json will create JSON arrays, so round-trip
> fidelity is lost.

Yeah, this has come up before; one recent discussion is at
https://www.postgresql.org/message-id/flat/CAPpdape1SieipHCyZVbgtkb5NaD00FKGjiEoqfYj%3DPi%2B9ffisg%40mail.gmail.com

Basically, these functions weren't built to process nested structures
recursively, and making them do so is a bit more work than anyone has
seen fit to put into them yet. We'd accept a patch ...

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message alf 2016-10-14 10:22:03 BUG #14370: pgagent_96 service typo?
Previous Message Peter Geoghegan 2016-10-13 17:27:15 Re: BUG #14344: string_agg(DISTINCT ..) crash