Re: additional json functionality - Mailing list pgsql-hackers

From Andrew Dunstan
Subject Re: additional json functionality
Date
Msg-id 528D04C8.9070307@dunslane.net
Whole thread Raw
In response to Re: additional json functionality  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 11/20/2013 01:36 PM, Tom Lane wrote:
>
> You'd have to make the data self-identifying (which I think was the plan
> already), and ensure that *every* function taking "json" could cope with
> both formats on input.  The typmod could only be expected to be enforced
> when storing or explicitly casting to one subformat, much like operations
> on "numeric" pay little attention to the original precision/scale if any.
>
> I agree that this solution isn't terribly workable, mainly because it'd
> break any third-party C functions that take json today.
>
>             


Yeah, I had come to this conclusion. I don't think we can bolt on 
typmods after the event.

I don't think having a separate "jsonb" type will be a tragedy.

I'm already planning on overloading the existing json functions and 
operators.


cheers

andrew



pgsql-hackers by date:

Previous
From: Josh Berkus
Date:
Subject: Re: Data corruption issues using streaming replication on 9.0.14/9.2.5/9.3.1
Next
From: Fabrízio de Royes Mello
Date:
Subject: [PATCH] Store Extension Options