Re: pgsql: Fix documentation of argument type of json_agg and jsonb_agg - Mailing list pgsql-committers

From Andrew Dunstan
Subject Re: pgsql: Fix documentation of argument type of json_agg and jsonb_agg
Date
Msg-id 5498A4D6.8060107@dunslane.net
Whole thread Raw
In response to Re: pgsql: Fix documentation of argument type of json_agg and jsonb_agg  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: pgsql: Fix documentation of argument type of json_agg and jsonb_agg  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-committers
On 12/22/2014 02:34 PM, Tom Lane wrote:
> Andrew Dunstan <andrew@dunslane.net> writes:
>> Fix documentation of argument type of json_agg and jsonb_agg
>> json_agg was originally designed to aggregate records. However, it soon
>> became clear that it is useful for aggregating all kinds of values and
>> that's what we have on 9.3 and 9.4, and in head for it and jsonb_agg.
>> The documentation suggested otherwise, so this fixes it.
> Claiming that the argument type is "expression" is not a fix.  I don't
> mind using that terminology in the first table column, but the second
> column is supposed to be the truth not handwaving.
>
> The actual declaration of the argument type is "anyelement", and I think
> we use that to document other such functions.
>
>

Oh, I thought I had seen "expression" there. It looks like we're using
"any" elsewhere, so I'll use that. While I'm at it I'll remove the quote
marks around the arguments to json_object_agg().



pgsql-committers by date:

Previous
From: Tom Lane
Date:
Subject: Re: pgsql: Fix documentation of argument type of json_agg and jsonb_agg
Next
From: Andrew Dunstan
Date:
Subject: pgsql: Further tidy up on json aggregate documentation