Re: jsonb and nested hstore

From: Merlin Moncure <mmoncure(at)gmail(dot)com>
To: Andres Freund <andres(at)2ndquadrant(dot)com>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, Teodor Sigaev <teodor(at)sigaev(dot)ru>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: jsonb and nested hstore
Date: 2014-02-11 00:33:45
Message-ID: CAHyXU0z_YqxSD=B0PccHk158gvdw+KRQKE9ecyx35pOZDh8Ecw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Feb 10, 2014 at 6:24 PM, Andres Freund <andres(at)2ndquadrant(dot)com> wrote:
> And if we add a new format version in 9.5 we need to make it discernible
> from the 9.4 format. Without space for a format indicator we'd have to
> resort to ugly tricks like defining the high bit in the first byte set
> indicates the new version. I don't see the improvement here.

Point being: a 9.5 binary format reading server could look for a magic
token in the beginning of the file which would indicate the presence
of a header. The server could then make intelligent decisions about
reading data inside the file which would be follow exactly the same
kinds of decisions binary format consuming client code would make.
Perhaps it would be a simple check on version, or something more
complex that would involve a negotiation. The 'format' indicator,
should version not be precise enough, needs to be in the header, not
passed with every instance of the data type, and certainly not for one
type in the absence of others.

merlin

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2014-02-11 00:39:39 Re: jsonb and nested hstore
Previous Message Tom Lane 2014-02-11 00:24:44 Re: jsonb and nested hstore