Subject Re: Bug or feature (left join)
Author ainpoissee
--- In firebird-support@yahoogroups.com, "Adam" <s3057043@...> wrote:
>
> In your original query, you have three bits AND'd together in your
> where clause. (Make sure your brackets are where you expect them to be
> if you didn't realise that).

They are (see my reply to Arno).


> Start by removing the where clause and running the query, you should
> see that record. Then add the first of the 3 AND'd clauses. Do you
> still see the record? If not, investigate it. If so, add the second,
> repeat process.

The problem is related to the condition involving TAB_Graafik.Kuupaev, ie

(((TAB_Graafik.Kuupaev<='31.10.2006')AND(TAB_Graafik.Kuupaev>='01.10.2006'))OR(TAB_Graafik.Kuupaev
IS NULL))

part of the WHERE. If I drop this, the record TAB_Tooleping.Tooline=1
shows up in result. I now commented out parts of this condition and

((TAB_Graafik.Kuupaev<='31.10.2006')OR(TAB_Graafik.Kuupaev IS NULL))

also returns "Tooline=1" record! But of course, then also some
unwanted records will be in result.


ain