Re: additional json functionality

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: additional json functionality
Дата
Msg-id CA+TgmoagjFfJst=9kSu4rZatCE8SRuOQCH_h-_YW=4_c687GTA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: additional json functionality  (Greg Stark <stark@mit.edu>)
Список pgsql-hackers
On Wed, Nov 20, 2013 at 12:50 PM, Greg Stark <stark@mit.edu> wrote:
>> For one thing, our storage format is different from theirs (better,
>> frankly), and as a result is not compliant with their "standard".
>
> Not being super familiar with either BSON our JSONB what advantages are we
> gaining from the difference?

BSON assumes, for example, that all integers fit in 64-bits and all
floating point values can be accurately represented as float8.  So not
all JSON objects can be represented as BSON without loss of
information.

BSON also adds a bunch of extra types that are not part of JSON, like
timestamps, regular expressions, and embedded documents.  So not all
BSON objects can be represented as JSON without loss of information.

While it's tempting to think that BSON is a serialization format for
JSON, and the name is meant to suggest that, it really isn't.  It's
just a serialization format for approximately whatever the authors
thought would be useful, which happens to be kinda like JSON.  Sorta.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



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

Предыдущее
От: Kevin Grittner
Дата:
Сообщение: Re: Suggestion: Issue warning when calling SET TRANSACTION outside transaction block
Следующее
От: Gurjeet Singh
Дата:
Сообщение: Re: Proof of concept: standalone backend with full FE/BE protocol