Skip site navigation (1) Skip section navigation (2)

Re: PATCH: Add hstore_to_json()

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: "David E(dot) Wheeler" <david(at)kineticode(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: PATCH: Add hstore_to_json()
Date: 2009-12-30 02:14:46
Message-ID: 603c8f070912291814r650810bao87b5e984caedffb5@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-hackers
On Fri, Dec 18, 2009 at 4:39 PM, Peter Eisentraut <peter_e(at)gmx(dot)net> wrote:
> On fre, 2009-12-18 at 11:51 -0500, Robert Haas wrote:
>> On Fri, Dec 18, 2009 at 11:32 AM, David E. Wheeler <david(at)kineticode(dot)com> wrote:
>> > On Dec 18, 2009, at 4:49 AM, Peter Eisentraut wrote:
>> >
>> >> Should we create a json type before adding all kinds of json formatted
>> >> data?  Or are we content with json as text?
>> >
>> > json_data_type++
>>
>> What would that do for us?
>
> At the moment it would be more of a placeholder, because if we later
> decide to add full-blown JSON-constructing and -destructing
> functionality, it would be difficult to change the signatures of all the
> existing functionality.

I've been mulling this over and I think this is a pretty good idea.
If we could get it done in time for 8.5, we could actually change the
output type of EXPLAIN (FORMAT JSON) to the new type.  If not, I'm
inclined to say that we should postpone adding any more functions that
generate json output until such time as we have a real type for it.  I
wouldn't feel too bad about changing the output type of EXPLAIN
(FORMAT JSON) from text to json in 8.6, because it's relatively
difficult to be depending on that for anything very important.  It's
much easier to be depending on something like this, and changing it
later could easily break working applications.

Anyone have an interest in taking a crack at this?

...Robert

In response to

Responses

pgsql-hackers by date

Next:From: Robert HaasDate: 2009-12-30 02:17:49
Subject: Re: Stats for inheritance trees
Previous:From: Tom LaneDate: 2009-12-30 02:12:10
Subject: Re: Stats for inheritance trees

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group