Subject | Left Outer Join assistance |
---|---|
Author | Adam |
Post date | 2004-12-09T04:53:04Z |
Hi all,
I just came across something which I didn't anticipate, and was
wondering why it behaves this way:
select b.*
from tablea a
left outer join Tableb b
on (a.ID = b.TableaID)
where a.id = :idno
Normally the query works fine, but when there are no matching idno
records that match in table A, one record is still returned by this
query (all the fields are null).
I am trying to select all the records from tableb that when joined to
tablea have the one IDNo.
I just came across something which I didn't anticipate, and was
wondering why it behaves this way:
select b.*
from tablea a
left outer join Tableb b
on (a.ID = b.TableaID)
where a.id = :idno
Normally the query works fine, but when there are no matching idno
records that match in table A, one record is still returned by this
query (all the fields are null).
I am trying to select all the records from tableb that when joined to
tablea have the one IDNo.