weird sql result with date

Ruslan Zasukhin sunshine at public.kherson.ua
Fri Aug 26 20:31:32 CDT 2005


On 8/26/05 4:53 PM, "Florian Bogeschdorfer" <fb at memedia.de> wrote:

> V4MD1.1 client
> 
> Hi! I have this script:
> 

> z=valselectreturncursor("SELECT Z_DAY_KD_ID,geburtsdatum FROM
> Z_DAY,KUNDENTable WHERE Z_DAY_KD_ID<>0 AND Z_DAY_KD_ID=KD_ID AND
> geburtsdatum<=26.08.1946 AND geburtsdatum>=27.08.1965")
> 
> these are the results:
> 
> put valgetcurrentrecord(z)
> 
> -- [#Z_DAY_KD_ID: 4509, #geburtsdatum: "17.09.1983"]
>  
> put valcursorreccount(z)
> -- 70904
> 
> Infact I would expect 0 results. Is my sql wrong?

SELECT Z_DAY_KD_ID,geburtsdatum
FROM Z_DAY, KUNDENTable
WHERE 
    Z_DAY_KD_ID <> 0
AND Z_DAY_KD_ID = KD_ID
AND geburtsdatum <= 26.08.1946 AND geburtsdatum >= 27.08.1965


* add ()

* make sure that fields of the same table are grouped together
    for 1.x this was important.

-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]




More information about the Valentina mailing list