Re: Feature Request: JSON input for hstore - Mailing list pgsql-hackers

From Robert Haas
Subject Re: Feature Request: JSON input for hstore
Date
Msg-id 603c8f070909141645u81195cbq89ad1749656ff484@mail.gmail.com
Whole thread Raw
In response to Re: Feature Request: JSON input for hstore  ("David E. Wheeler" <david@kineticode.com>)
List pgsql-hackers
On Mon, Sep 14, 2009 at 7:42 PM, David E. Wheeler <david@kineticode.com> wrote:
> On Sep 14, 2009, at 4:32 PM, Robert Haas wrote:
>
>>> What's wrong with just using a variant of the type input function? With
>>> a parameterized insert, it doesn't seem like it's really placing much of
>>> a burden on the application.
>>
>> Agreed, I was thinking the same thing.
>
> And the type output function, too. Not sure how you'd configure that,
> though.

Well I don't think you really need any them to BE the type
input/output functions.  You just need

hstore_to_json(hstore) returns text
json_to_hstore(text) returns json

Insert into your query where appropriate.

...Robert


pgsql-hackers by date:

Previous
From: "David E. Wheeler"
Date:
Subject: Re: Feature Request: JSON input for hstore
Next
From: ljb
Date:
Subject: Patch for 1-byte buffer overflow in libpq PQencryptPassword