Re: Undocumented array_val[generate_series(...)] functionality? - Mailing list pgsql-general

From Tom Lane
Subject Re: Undocumented array_val[generate_series(...)] functionality?
Date
Msg-id 2947769.1626100021@sss.pgh.pa.us
Whole thread Raw
In response to Re: Undocumented array_val[generate_series(...)] functionality?  (Dean Rasheed <dean.a.rasheed@gmail.com>)
Responses Re: Undocumented array_val[generate_series(...)] functionality?  ("David G. Johnston" <david.g.johnston@gmail.com>)
List pgsql-general
Dean Rasheed <dean.a.rasheed@gmail.com> writes:
> BTW, this is something that started working in PG10 (in 9.6, an error
> is thrown), and I think that it's a result of this release note item,
> which matches your conclusions:
>   Change the implementation of set-returning functions appearing in
>   a query's SELECT list (Andres Freund)

Interesting.  When I first looked at this thread I figured "oh, that's
always worked, nothing to see here".  But you're right, we didn't use
to allow SRFs in subscripts.  Still, I'm with David that no new docs
are needed.  IMO the former restriction was the surprising thing, and
the current behavior is simply what one would expect from assembling
those parts in that order.

            regards, tom lane



pgsql-general by date:

Previous
From: Jeff Ross
Date:
Subject: Re: Removing a subscription that does not exist
Next
From: "David G. Johnston"
Date:
Subject: Re: Undocumented array_val[generate_series(...)] functionality?