Re: PATCH: Add hstore_to_json() - Mailing list pgsql-hackers

From Andrew Dunstan
Subject Re: PATCH: Add hstore_to_json()
Date
Msg-id 4B40BF33.1090305@dunslane.net
Whole thread Raw
In response to Re: PATCH: Add hstore_to_json()  (Hitoshi Harada <umi.tanuki@gmail.com>)
Responses Re: PATCH: Add hstore_to_json()  ("David E. Wheeler" <david@kineticode.com>)
Re: PATCH: Add hstore_to_json()  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers

Hitoshi Harada wrote:
> 2010/1/3 Andrew Dunstan <andrew@dunslane.net>:
>   
>> Hitoshi Harada wrote:
>>     
>>> A question: Isn't there no possibility that we have our own
>>> implementation to handle JSON (i.e. no use of external libraries)?
>>>
>>>
>>>
>>>       
>> Why should we reinvent a wheel someone else has already invented? This is
>> what shared libraries are all about.
>>     
> Because what we need may be another wheel nobody has already invented.
> I don't deny to use one of external libraries but don't like to decide
> specification by their specifications.
>
>
>   

OK, we really need to stop being abstract and say what operations we want.

I think the minimal functionality I'd want is:
   convert record to JSON   convert JSON to record   extract a value, or set of values, from JSON   composition of
JSON

Now all the libraries I have looked at (briefly) would require some code 
to provide for those, possibly quite a bit of code, but that doesn't 
mean we should just start from scratch and write our own JSON parser too.

cheers

andrew



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Cancelling idle in transaction state
Next
From: Peter Eisentraut
Date:
Subject: Re: win32 socket definition