Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: should one use ANSI join syntax when writing an Oracle application?

RE: should one use ANSI join syntax when writing an Oracle application?

From: Wolfgang Breitling <breitliw_at_centrexcc.com>
Date: Wed, 18 Oct 2006 06:16:25 -0700
Message-ID: <1161177385.4536292993859@webmail.hosting.telus.net>


Quoting Eric Buddelmeijer <eric.buddelmeijer_at_elegant.nl>:

> There is IMHO another important difference between a join clause and a where
> clause. With a join clause you add more data to be examined and with a where
> clause you reduce the amount of relevant data. Two very different things. I
> like to see things be made explicit. Using the same where clause to do 2
> different things is not explicit enough for me.
> Eric.
>

I beg to differ. It is not the join predicate in the where clause that adds more data, it is the additional table(s) in the from clause which add more rows by virtue of the implied cartesian join(s). The join predicate in the where clause applies a condition to reduce the number of rows in the resultset, just like a scalar predicate.
In order to be precise the new join syntax needs to add the predicates previously specified in the where clause in an "ON" or "USING" clause. Hardly any clearer and certainly a lot wordier. And I'd like to see an example of a query using the new syntax that joins 3 or more inline views.

-- 
regards

Wolfgang Breitling
Oracle 7,8,8i,9i OCP DBA
Centrex Consulting Corporation
www.centrexcc.com

--
http://www.freelists.org/webpage/oracle-l
Received on Wed Oct 18 2006 - 08:16:25 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US