From: Tom Lane <tgl@sss.pgh.pa.us>
To: David G Johnston <david.g.johnston@gmail.com>
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #12000: "CROSS JOIN" not equivalent to ","
Date: Tue, 18 Nov 2014 12:55:51 -0500
Message-ID: <13989.1416333351@sss.pgh.pa.us> (raw)
In-Reply-To: <1416332994261-5827399.post@n5.nabble.com>
References: <20141118171126.2479.55006@wrigleys.postgresql.org>
<2468.1416331743@sss.pgh.pa.us>
<1416332994261-5827399.post@n5.nabble.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
David G Johnston <david.g.johnston@gmail.com> writes:
> Tom Lane-2 wrote
>> A simple "fix" would be to remove the claim about "," and just compare
>> CROSS JOIN to INNER JOIN ON TRUE. I'm not really convinced that's an
>> improvement ...
> How about adding the following to that sentence:
> "However, in the presence of three or more joined relations it is
> recommended to only use either explicit joins or commas since mixing them
> introduces non-obvious join order differences."
I don't think it's the place of the manual to be prescriptive about style;
at least, not here.
We could do something like "<CROSS JOIN example> is equivalent to <INNER JOIN ON
TRUE example>. <CROSS JOIN example> is also equivalent to <example with
comma>, but in cases with more than two tables this equivalence is not
exact, because JOIN binds more tightly than comma."
Or maybe put the "but" in a footnote.
regards, tom lane
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
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: tgl@sss.pgh.pa.us, david.g.johnston@gmail.com
Subject: Re: BUG #12000: "CROSS JOIN" not equivalent to ","
In-Reply-To: <13989.1416333351@sss.pgh.pa.us>
References: <20141118171126.2479.55006@wrigleys.postgresql.org> <2468.1416331743@sss.pgh.pa.us> <1416332994261-5827399.post@n5.nabble.com> <13989.1416333351@sss.pgh.pa.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