Subject Re: [firebird-support] date functions
Author Helen Borrie
At 09:21 AM 29/01/2004 +0200, you wrote:
>Helen, This is an excerpt from our previous discussion. We subsequently did
>as advised below and it appeared to be 100% _UNTIL_ the procedure fires at
>00:00 hours and then some records were omitted. On inspection we found the
>following
>
>The following query does not return data as expected
>
>select cast('TODAY' as TimeStamp) today, /* fine */
> cast(cast(date_out as date) as TimeStamp) date_out, /* Fine */
> cast(cast(date_out as timeStamp)as date) /* expected to display only
>date, but still has the hours and minutes with */
>
> from visit_accom_days
>
>
>
>Do you have any clues please?

Not a one. Just tested it on RC8 in both isql and IB_SQL and get date-only
in both cases. Even a literal right at midnight:

select cast(cast('2004-01-29 00:00:00.0000' as timeStamp)as date)
from rdb$database
CAST
=========
2004-01-29

You don't have any DISTINCT there, or inner joins, that might be causing
records to get "lost"?

/hb