From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> |
Cc: | manlio(dot)perillo(at)gmail(dot)com, "pgsql-bugs(at)postgresql(dot)org" <pgsql-bugs(at)postgresql(dot)org> |
Subject: | Re: BUG #14016: Incomplete documentation of IN subquery expression |
Date: | 2016-04-26 20:27:37 |
Message-ID: | 20160426202737.GA13058@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
On Fri, Mar 11, 2016 at 10:02:01AM -0700, David G. Johnston wrote:
> On Fri, Mar 11, 2016 at 9:39 AM, <manlio(dot)perillo(at)gmail(dot)com> wrote:
>
> At the end of the documentation for VALUE (sql-values.html), there is the
> following tip:
> "For simple IN tests, it's better to rely on the list-of-scalars form of IN
> than to write a VALUES query as shown above"
>
> However there is no reference to the "list-of-scalars" forms of IN, in the
> functions-subquery.html page. It is only reported that the supported
> syntax
> is "expression IN (subquery)"
>
> The reference was available in an old version (7.3), where the manual
> documented both the scalar form and sub query form:
> "expression IN (value[, ...])"
>
>
> It was moved...
>
> http://www.postgresql.org/docs/9.5/interactive/functions-comparisons.html#
> AEN20283
>
> The interpretation being that a "list of scalars" is, in this situation,
> semantically equivalent to an array - though having the later you would have to
> use "=ANY(array)" instead of "IN"
>
> Apparently someone disagreed with the note in the subquery section:
>
> >>>Note: This form of IN is not truly a subquery expression, but it seems best
> to document it in the same place as subquery IN.
Does the attached patch improve this?
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ As you are, so once was I. As I am, so you will be. +
+ Ancient Roman grave inscription +
Attachment | Content-Type | Size |
---|---|---|
in.diff | text/x-diff | 1.4 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | David G. Johnston | 2016-04-26 21:00:39 | Re: BUG #14016: Incomplete documentation of IN subquery expression |
Previous Message | Devrim Gündüz | 2016-04-26 17:19:28 | Re: BUG #14014: postgresql95-setup script determines PGDATA wrongly |