Why won’t this work in Oracle?
Is there a way to make this work?
FROM table1 a,
table2 b,
table3 c
WHERE a.some_id = '10'
AND a.other_id (+)= b.other_id
AND a.other_id (+)= c.other_id
I want table1 to be left outer joined on multiple tables…
If I try to change it to use an ANSI join, I get compilation errors. I did the following:
FROM table2 b, table3 c
LEFT JOIN table1 a ON a.other_id = b.other_id and a.other_id = c.other_id
OK, looking at the examples from the Oracle docs, my recollection of the syntax was correct, so I’m turning my comment into an answer. Assuming that your goal is a left outer join where A is the base table, and you join matching rows from B and C, rewrite your query as follows (note that I’m just changing the prefixes; I like to have the source rowset on the right).
If that’s not what you’re trying to do, then the query is borked: you’re doing a cartesian join of B and C, and then attempting an outer join from that partial result to A, with an additional predicate on A. Which doesn’t make a lot of sense.