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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

left outer join to multiple tables

Status
Not open for further replies.

mdl2

Programmer
Apr 12, 2002
25
0
0
CA
I am getting ORA-01417: a table may be outer joined to at most one other table


AND CA.CASE_ID = CEYS.CASE_ID (+)
AND RPT.HRE_REPORTS_ID = CEYS.HRE_REPORTS_ID (+)
AND CA.CASE_ID = ICS.CASE_ID (+)
AND RPT.HRE_REPORTS_ID = ICS.HRE_REPORTS_ID (+)

What I am attempting to do is
I have a ca record which is an individual person. I want to get people that have had payments in the previous effective month of my selected report which is in the RPT table. If they have a CEYS record for the report period I want them or if they only have a ICS record for the report period I want them
for multiple programs (CEYS ICS) which has the effective date and the ca and I am trying to join them into 1 record
with a case statement
CASE ICS & CEYS
ICS only
CEYS only
END

Any suggestions?
 
You can sometimes get round these sort of problems by joining two of the tables in an inline view and then joining that back to the third table.
 
You could UNION (ANY or ALL, take your pick) two SELECTs, the first querying ICS, the second CEYS.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top