Subject | Re: Bug or feature (left join) |
---|---|
Author | ainpoissee |
Post date | 2006-11-17T19:57:30Z |
--- In firebird-support@yahoogroups.com, "Ann W. Harrison"
clause.
See my original query, there I have
LEFT JOIN TAB_Graafik ON(TAB_Graafik.Tooleping = TAB_Tooleping.UID)
and in the WHERE I have condition
(((TAB_Graafik.Kuupaev<='31.10.2006')AND(TAB_Graafik.Kuupaev>='01.10.2006'))OR(TAB_Graafik.Kuupaev
IS NULL))
but this query doesn't return record from TAB_Tooleping which don't
have record in TAB_Graafik in given date range. But date range is ORed
with IS NULL condition, so it should!
ain
>I want to use parameters and AFAIK parameters can't be used in JOIN
> Conditions that apply to the right hand tables in left joins are
> better left in the JOIN ON clause.
clause.
> If you feel you really mustI think I do!
> put them in the WHERE clause, you must allow null values for the
> referenced fields.
See my original query, there I have
LEFT JOIN TAB_Graafik ON(TAB_Graafik.Tooleping = TAB_Tooleping.UID)
and in the WHERE I have condition
(((TAB_Graafik.Kuupaev<='31.10.2006')AND(TAB_Graafik.Kuupaev>='01.10.2006'))OR(TAB_Graafik.Kuupaev
IS NULL))
but this query doesn't return record from TAB_Tooleping which don't
have record in TAB_Graafik in given date range. But date range is ORed
with IS NULL condition, so it should!
ain