Jump to content

Sql From H3Ll


LSW

Recommended Posts

I am starting a rewrite of a ASP-Classic application into Java.

 

First off I cannot believe what I am seeing... 1 page with two massive SQL statements... as in 89 lines long! Including 17 sub-selects!

 

Note to beginners, you should never go deeper than a few sub-selects and avoid that if you can.

 

So aside from not being able to follow 17 sub-selects I find this at the end multiple times:

 

...

service.s = status.ssn(+)  AND
service.s = lwop.ssn(+)  AND
service.s = election_trans.ssn(+);

 

 

This may be old style SQL, I don't know, but I cannot find out what the (+) at the end does. No one in the office seems to know either. So anyone have an idea?

Link to comment
Share on other sites

This is in fact, the original Oracle proprietary format equivalent to an “Outer Join” before they went to the ANSI standard we use today.

 

http://oracledba.ezpowell.com/oracle/ocp/Joins.html

 

My problem was thinking only in terms of the "languages", ie. it must be SQL or ASP (VBScript) and not considering it being Oracle specific until someone mentioned that.

 

bash2.gif

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...