Subject Re: Bug in firebird 1.5?? left joining
Author johnsparrowuk
Hi Svein,

I didn't know about the restriction on the WHERE clause... I use this
structure a lot. Are you sure it's not ok to say:

select a.* from a left join b on a.id = b.id where b.id is null

??? If it's not valid SQL, shouldn't Firebird refuse to accept it?
Also, if it's not valid to reference the 'outer' side of an outer
join, does that mean you can't have a WHERE clause at all in a FULL
OUTER?!?!?!


> select * from currentpeople c
> left join finishedpeople f
> on c.person = f.person and f.person is null

Isn't equivalent. Wouldn't that infer that c.person = f.person = NULL
(or should I say 'IS NULL'!)? and since 'c.person is null'
and 'f.person is null', presumably c.person will never equal
f.person?? (null == null always being null)

--- In firebird-support@yahoogroups.com, "Svein Erling"
<svein.erling.tysvaer@k...> wrote:
> When Arno says it is a bug, I'm not going to argue against it, but
> what is this select actually supposed to do? I thought that the
right
> table of a left join could only be referenced in the join clause
and
> not in the where clause. Is your select equivalent to
>
> select * from currentpeople c
> left join finishedpeople f
> on c.person = f.person and f.person is null
>
> or are you trying to do something different?
>
> Just curious and confused,
> Set