[NEW][SQL] BETWEEN implemented

Claudius Sailer Claudius at sailer-online.de
Thu Jun 26 19:24:49 CDT 2003


Hi Ruslan,

Am Donnerstag, 26.06.03, um 17:02 Uhr (Europe/Berlin) schrieb Ruslan 
Zasukhin:

> 1) am I right that AnfangsZeit is DateTime field

Yes


> 2) then I think all right.
> Because in second query you say
>
>         AnfangsZeit BETWEEN 01.01.2002 AND 31.12.2002
>                                            ^^^^^^^^^^^^
> This is the same as:
>
>        AnfangsZeit BETWEEN 01.01.2002 AND 31.12.2002 00:00:00
>
> By the way!!!
> You need to use quotes around  dates:
>
>        AnfangsZeit BETWEEN '01.01.2002' AND '31.12.2002 00:00:00'
>
> So result is expected.
> You specify not full Date Time value, Valentina adds ZEROs.
>
> You think this is not correct?

It is correct now because I know it. I thought that when I use only the 
date that only the date is compared. But to know how it works is 
somthing that I can do now the right thing in my source code.

Thanks for this information


Claudius



More information about the Valentina mailing list