Re: Proposal: Add JSON support

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: Proposal: Add JSON support
Дата
Msg-id 4BB75CCD.1040906@dunslane.net
обсуждение исходный текст
Ответ на Re: Proposal: Add JSON support  (Mike Rylander <mrylander@gmail.com>)
Ответы Re: Proposal: Add JSON support
Список pgsql-hackers

Mike Rylander wrote:
>>
>> Here's my idea: the datatype should only allow strict JSON, but there
>> should be a function that accepts a liberal format, cleans it up to
>> make it strict JSON, and converts it to JSON.  I think making strict
>> JSON the default makes the most sense because:
>>  * Inputs to the database will most likely be coming from programs, not humans.
>>  * Output is expected to be valid JSON and work anywhere JSON should work.
>>  * Strict JSON is what more people would expect, I'd think.
>>     
>
> +1
>
>   

Yeah. That's the only thing that makes sense to me. We don't allow badly 
formed XML, for example, although we do allow document fragments (as 
required by the standard, IIRC). But we could sensibly have some 
function like 'cleanup_json(almost_json text) returns json'.

cheers

andrew


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: message clarifications
Следующее
От: Andrew Dunstan
Дата:
Сообщение: pgindent cleanup