Subject Re: [firebird-support] Date to seconds
Author Don Gollahon
Wouldn't it be something like:

select cast(mydatefld as timestamp)-cast('1/1/1970' as timestamp) * 86400 as
from mytable

I'm just guessing here. Haven't tried it. Subtracting 2 dates like this
and multiplying by 86400 does work in Delphi. Not sure in Sql.

""Martin"" <moirae@...> wrote in message
Could anyone help me please? I need to convert date to count of
seconds from Jan 1 1970 inside SP. I tried to make it with CAST(),
but I wasn't successful. What should be the right syntax or functions?


To unsubscribe from this group, send an email to:

Your use of Yahoo! Groups is subject to