Re: bug in json_to_record with arrays

Поиск
Список
Период
Сортировка
От Josh Berkus
Тема Re: bug in json_to_record with arrays
Дата
Msg-id 54763178.9050106@agliodbs.com
обсуждение исходный текст
Ответ на bug in json_to_record with arrays  (Josh Berkus <josh@agliodbs.com>)
Ответы Re: bug in json_to_record with arrays  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 11/26/2014 11:54 AM, Josh Berkus wrote:
> Tested on 9.4b3, 9.4rc1, 9.5devel
> 
> select * from json_to_record('
> {"id":1,"val":"josh","valry":["potter","chef","programmer"]}') as r(id
> int, val text, valry text[]);
> 
> ERROR:  missing dimension value
> 
> With some experimentation, I can't find any way to convert a JSON array
> to an array field using json_to_record or json_to_recordset.  I know
> this worked back in January, though.

Lemme take that back, it didn't work.  Just checked an old devel snapshot.

Looks like this is not intended to work, so the only bug is that we need
a less confusing error message.


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



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Josh Berkus
Дата:
Сообщение: bug in json_to_record with arrays
Следующее
От: Magnus Hagander
Дата:
Сообщение: Re: GSSAPI, SSPI - include_realm default