Subject | Re: [firebird-support] Re: Firebird 1.5 - CURRENT_TIMESTAMP difference |
---|---|
Author | Helen Borrie |
Post date | 2014-12-15T07:09:30Z |
At 11:14 a.m. 15/12/2014, emadour@... [firebird-support] wrote:
Listen to what Sean said: 'NOW' gives you the time at execution of the statement instance, whereas CURRENT_TIMESTAMP gives you the time at the start of the operation. So, if you have multiple instances of a statement running in a batch, they will all have the same CURRENT_TIMESTAMP but different timestamps if you use 'Now'. Why not create a test that uses both?
I hope you do know that single quotes and double quotes are not interchangeable in Firebird. The literal delimiter is single quotes.
Helen Borrie, Support Consultant, IBPhoenix (Pacific)
Author of "The Firebird Book" and "The Firebird Book Second Edition"
http://www.firebird-books.net
__________________________________________________________________
>Unfortunately we're using 1.5 so "NOW" isn't available to us.Wrong. 'NOW' or 'now' was inherited from InterBase. CURRENT_TIMESTAMP came with IB6 or Fb 1.0, afair.
Listen to what Sean said: 'NOW' gives you the time at execution of the statement instance, whereas CURRENT_TIMESTAMP gives you the time at the start of the operation. So, if you have multiple instances of a statement running in a batch, they will all have the same CURRENT_TIMESTAMP but different timestamps if you use 'Now'. Why not create a test that uses both?
I hope you do know that single quotes and double quotes are not interchangeable in Firebird. The literal delimiter is single quotes.
>We're running the statements in real-time so a 30 minute difference is definitely wrong.. It is also exactly 30 minutes which leads me to believe there's some kind of funny offset due to timezone or something to that effect that we aren't seeing for whatever reason.No such thing exists.
>I thought if I figured out where the "CURRENT_TIMESTAMP" statement is pulling its time from I would know where to look for the issue.System clock time. Maybe Server2003 has some anomaly related to daylight saving time...just a thought.
Helen Borrie, Support Consultant, IBPhoenix (Pacific)
Author of "The Firebird Book" and "The Firebird Book Second Edition"
http://www.firebird-books.net
__________________________________________________________________