From: Bruce Momjian <bruce@momjian.us>
To: David G. Johnston <david.g.johnston@gmail.com>
Cc: Manlio Perillo <manlio.perillo@gmail.com>
Cc: pgsql-bugs@postgresql.org <pgsql-bugs@postgresql.org>
Subject: Re: BUG #14016: Incomplete documentation of IN subquery expression
Date: Tue, 26 Apr 2016 20:20:10 -0400
Message-ID: <20160427002010.GC13058@momjian.us> (raw)
In-Reply-To: <CAKFQuwaV9t0kRQPsnskF9yQ=L+P+TvDYMV+X0xnGxHz=5-XG6g@mail.gmail.com>
References: <20160311163928.6674.94707@wrigleys.postgresql.org>
<CAKFQuwYR0xCbQS=fpv50Jqnsii=Y+B5sgkzzkY_PJG6M5fR1OQ@mail.gmail.com>
<20160426202737.GA13058@momjian.us>
<CAKFQuwaV9t0kRQPsnskF9yQ=L+P+TvDYMV+X0xnGxHz=5-XG6g@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
On Tue, Apr 26, 2016 at 02:00:39PM -0700, David G. Johnston wrote:
> On Tue, Apr 26, 2016 at 1:27 PM, Bruce Momjian <bruce@momjian.us> wrote:
> > >>>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?
>
>
> I'd append "scalar" to the id to distinguish in from the subquery version.
> Otherwise any suggest I make seems like overkill. The main point being the
> "list of scalars" is not a term we use on the referenced page, and the chapter
> header indicates "Row and Array" of which this is similar but technically
> neither.
>
> <sect2 id="functions-comparisons-in-scalar"> [...]
>
> [...] rely on the <link linkend="functions-comparison-in-scalar">array</link>
> form of [...]
Sorry, there was already a link in that place --- I had linked to the
wrong spot. New patch attached.
--
Bruce Momjian <bruce@momjian.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 +
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugsAttachments:in.diff (text/x-diff, 916B) downloaddiff --git a/doc/src/sgml/ref/values.sgml b/doc/src/sgml/ref/values.sgmlnew file mode 100644index 0fb3cd7..f91ceb0
*** a/doc/src/sgml/ref/values.sgml
--- b/doc/src/sgml/ref/values.sgml
*************** WHERE ip_address IN (VALUES('192.168.0.1
*** 219,225 ****
<tip>
<para>
For simple <literal>IN</> tests, it's better to rely on the
! list-of-scalars form of <literal>IN</> than to write a <command>VALUES</>
query as shown above. The list of scalars method requires less writing
and is often more efficient.
</para>
--- 219,226 ----
<tip>
<para>
For simple <literal>IN</> tests, it's better to rely on the
! <link linkend="functions-subquery-in">list-of-scalars</link> form
! of <literal>IN</> than to write a <command>VALUES</>
query as shown above. The list of scalars method requires less writing
and is often more efficient.
</para>
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: bruce@momjian.us, david.g.johnston@gmail.com, manlio.perillo@gmail.com
Subject: Re: BUG #14016: Incomplete documentation of IN subquery expression
In-Reply-To: <20160427002010.GC13058@momjian.us>
References: <20160311163928.6674.94707@wrigleys.postgresql.org> <CAKFQuwYR0xCbQS=fpv50Jqnsii=Y+B5sgkzzkY_PJG6M5fR1OQ@mail.gmail.com> <20160426202737.GA13058@momjian.us> <CAKFQuwaV9t0kRQPsnskF9yQ=L+P+TvDYMV+X0xnGxHz=5-XG6g@mail.gmail.com> <20160427002010.GC13058@momjian.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox