V4RB: date compare fault

Claudius Sailer Claudius at sailer-online.de
Sun Feb 2 12:17:07 CST 2003


Hi,

I have in the database following relations

t1 --> t2
t2 --> t3
t4 --> t3

and the following SQL-Statement works

SELECT t1.BDatum, t1.Betrag, t2.Kategorie_Name, t3.Bezeichnung, 
t4.Satz, t4.AnfangsDatum, t4.EndDatum
FROM Buchungen t1, Kategorien t2, MWSt t3, MWStSatz t4
WHERE t1.Kategorie_ID=t2.RecID
AND t2.MWSt=t3.RecID
AND t4.MWSt=t3.RecID

the following which I need not

SELECT t1.BDatum, t1.Betrag, t2.Kategorie_Name, t3.Bezeichnung, 
t4.Satz, t4.AnfangsDatum, t4.EndDatum
FROM Buchungen t1, Kategorien t2, MWSt t3, MWStSatz t4
WHERE t1.Kategorie_ID=t2.RecID
AND t1.BDatum>=t4.AnfangsDatum
AND t2.BDatum<t4.EndDatum
AND t2.MWSt=t3.RecID
AND t4.MWSt=t3.RecID

no try with comparing dates work.

SELECT t1.BDatum, t1.Betrag, t2.Kategorie_Name, t3.Bezeichnung, 
t4.Satz, t4.AnfangsDatum, t4.EndDatum
FROM Buchungen t1, Kategorien t2, MWSt t3, MWStSatz t4
WHERE t1.Kategorie_ID=t2.RecID
AND t1.BDatum=t4.AnfangsDatum
AND t2.MWSt=t3.RecID
AND t4.MWSt=t3.RecID

this shows me the correct result, but comparing without equal gives me 
no result...
I tested all possibilities with brackets without any better result. Any 
idea how I can handle or fix this in RB to make it usable? My idea was 
to fill a new table without the Date-restriction and use a 
delete-Statement afterwords with a date restriction, but is it much 
more easier to come to the same result?

Is this problem fixed in 2.0 or in 1.9.7? I know that I had this 
problem some times ago and got the answer that the bug is known.

Thanks for help


Claudius



More information about the Valentina mailing list