Re: Duplicate JSON Object Keys

Поиск
Список
Период
Сортировка
Искать
От
David E. Wheeler
Тема
Re: Duplicate JSON Object Keys
Дата
Msg-id
46479E46-F635-44BB-8B44-1357F623F1A8@justatheory.com
Ответ на
Список
Дерево обсуждения
Duplicate JSON Object Keys "David E. Wheeler" <david@justatheory.com>
Re: Duplicate JSON Object Keys Andrew Dunstan <andrew@dunslane.net>
Re: Duplicate JSON Object Keys Robert Haas <robertmhaas@gmail.com>
Re: Duplicate JSON Object Keys Hannu Krosing <hannu@2ndQuadrant.com>
Re: Duplicate JSON Object Keys Alvaro Herrera <alvherre@2ndquadrant.com>
Re: Duplicate JSON Object Keys "David E. Wheeler" <david@justatheory.com>
Re: Duplicate JSON Object Keys Gavin Flower <GavinFlower@archidevsys.co.nz>
Re: Duplicate JSON Object Keys Andrew Dunstan <andrew@dunslane.net>
Re: Duplicate JSON Object Keys "David E. Wheeler" <david@justatheory.com>
Re: Duplicate JSON Object Keys Andrew Dunstan <andrew@dunslane.net>
Re: Duplicate JSON Object Keys Hannu Krosing <hannu@2ndQuadrant.com>
Re: Duplicate JSON Object Keys Andrew Dunstan <andrew@dunslane.net>
Re: Duplicate JSON Object Keys Josh Berkus <josh@agliodbs.com>
Re: Duplicate JSON Object Keys Hannu Krosing <hannu@krosing.net>
Re: Duplicate JSON Object Keys Andrew Dunstan <andrew@dunslane.net>
Re: Duplicate JSON Object Keys Robert Haas <robertmhaas@gmail.com>
Re: Duplicate JSON Object Keys "David E. Wheeler" <david@justatheory.com>
Re: Duplicate JSON Object Keys Hannu Krosing <hannu@2ndQuadrant.com>
Re: Duplicate JSON Object Keys Craig Ringer <craig@2ndquadrant.com>
Re: Duplicate JSON Object Keys Andres Freund <andres@2ndquadrant.com>
Re: Duplicate JSON Object Keys Andrew Dunstan <andrew@dunslane.net>
Re: Duplicate JSON Object Keys Gavin Flower <GavinFlower@archidevsys.co.nz>
Re: Duplicate JSON Object Keys Andrew Dunstan <andrew@dunslane.net>
Re: Duplicate JSON Object Keys "David E. Wheeler" <david@justatheory.com>
Re: Duplicate JSON Object Keys Andrew Dunstan <andrew@dunslane.net>
Re: Duplicate JSON Object Keys "David E. Wheeler" <david@justatheory.com>
Re: Duplicate JSON Object Keys Hannu Krosing <hannu@2ndQuadrant.com>
Re: Duplicate JSON Object Keys Noah Misch <noah@leadboat.com>
On Mar 8, 2013, at 1:01 PM, Alvaro Herrera  wrote:

>> If it does not meet these "semantic" constraints, then it is not
>> really JSON - it is merely JSON-like.
>> 
>> this sounds very much like MySQLs decision to support timestamp
>> "0000-00-00 00:00" - syntactically correct, but semantically wrong.
> 
> Is it wrong?  The standard cited says SHOULD, not MUST.

Yes, it is wrong, because multiple keys are specifically disallowed for accessing values. Hence this new error:
  david=# select json_get('{"foo": 1, "foo": 2}', 'foo');  ERROR:  field name is not unique in json object

I really don’t think that should be possible.

Best,

David

В списке pgsql-hackers по дате отправления
От: Alvaro Herrera
Дата:
Сообщение: Re: Duplicate JSON Object Keys
От: Gavin Flower
Дата:
Сообщение: Re: Duplicate JSON Object Keys
FAQ