Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

INNER JOIN with Oracle 8i

Status
Not open for further replies.

hlauwers

Technical User
Aug 20, 2003
58
BE
I have the folowwing query:

SELECT COUNT(*) FROM X INNER JOIN Y ON X.OID = Y.OID

When I try to run it via SQL*Plus an error occurs:

.ORA-00933 SQL command not properly ended
the error marks the JOIN keyword


what's wrong?
 
Thank you.

And a RIGHT JOIN ... would that be

Code:
WHERE X.OID = Y.OID(+)

?
 
HLauwers,

In Oracle, when you use the "(+)" symbol on an operand of a WHERE clause's relational expression (regardless of whether you put it on the "left" or "right" operand), it produces what we fondly call a "left outer join". The effect is a "join for otherwise 'left-out' records".

I would be interested in hearing one of our Oracle gurus postulate an explanation that focuses meaningfully on the theoretical use of the terms "left" versus "right" and "inner" versus "outer" as they apply to Oracle.

As far as I am aware, at least in the Oracle world, we do not meaningfully use what would appear as the converse terminology: "right-inner" join...It's just a join.

[santa]Mufasa
(aka Dave of Sandy, Utah, USA @ 16:12 (10Jun04) UTC (aka "GMT" and "Zulu"), 09:12 (10Jun04) Mountain Time)
 
Thanks for the info, SantaMufasa, it helped a lot.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top