Solved

SQL Where statement - column_name(+)

Posted on 2013-01-07
5
455 Views
Last Modified: 2013-01-07
I have inherited some old code and am wondering why the (+) was coded in this statement, as I have never seen it used before, and can find no reference to it on the internet.

WHERE        c.CASE_NUMBER = cz.CASE_NUMBER(+)

Thanks
0
Comment
Question by:ktylerconk
  • 2
  • 2
5 Comments
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 38752342
It is the old OUTER JOIN Oracle syntax.
0
 
LVL 45

Accepted Solution

by:
Kdo earned 25 total points
ID: 38752347
Hi tyler,

That's a legacy style of coding an outer join.

In the early days of SQL there were only inner joins.  When outer joins were added, Oracle adopted the (+) syntax to describe that the table is being outer joined.  (I've never cared for the syntax.)

As far as I know, it's not supported by any other vendor, and is deprecated by Oracle.  The Oracle SQL parser still accepts the syntax, but you shouldn't use it to code new SQL projects.


Good Luck,
Kent
0
 

Author Closing Comment

by:ktylerconk
ID: 38752358
Thank you Kent!!
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 38752365
Here is the doc link that talks about it:

http://docs.oracle.com/cd/E11882_01/server.112/e26088/queries006.htm#SQLRF52354

I'm on fence with Kdo's post.  I've been Oracle and only Oracle for so long, I've still not quite mastered the ANSI join syntax and find it confusing (but I also haven't taken the time to figure it out).
0
 

Author Comment

by:ktylerconk
ID: 38752403
Thank you for the great article slightwv!  It should help me!
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Configuring and using Oracle Database Gateway for ODBC Introduction First, a brief summary of what a Database Gateway is.  A Gateway is a set of driver agents and configurations that allow an Oracle database to communicate with other platforms…
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
This video shows how to copy a database user from one database to another user DBMS_METADATA.  It also shows how to copy a user's permissions and discusses password hash differences between Oracle 10g and 11g.

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question