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

Home -> Community -> Usenet -> c.d.o.misc -> Re: Different syntax for LEFT JOIN

Re: Different syntax for LEFT JOIN

From: Michel Cadot <micadot{at}altern{dot}org>
Date: Mon, 22 Nov 2004 19:21:40 +0100
Message-ID: <41a22e4a$0$14321$626a14ce@news.free.fr>

"Ruslan Kogan" <ruslan00_at_yahoo.com> a écrit dans le message de news:d562b81c.0411212211.1893a476_at_posting.google.com...
> hi,
>
> I am just wondering if there is a difference in the following two syntaxes:
>
> SELECT *
> FROM TableA
> LEFT JOIN TableB ON
> TableA.id = TableB.id
>
> SELECT *
> FROM TableA, TableB
> WHERE
> TableA.id(+) = TableB.id
>
> is this correct? I am a little confused about where to position the '(+)'.
>
> Thanks heaps!!!

These two queries are different, the first one is an inner join and the last one an outer join. The Oracle equivalent for the first one is: select * from tableA, tableB where tableA.id = tableB.id;

The ISO equivalent for the second one is: select * from tableA right outer join tableB on (tableA.id=tableB.id);

-- 
Regards
Michel Cadot
Received on Mon Nov 22 2004 - 12:21:40 CST

Original text of this message

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