TypeTIMESTAMP WITHOUT TIME ZONE
Syntax
The optional precision argument is not supported in ESQL.
LOCALTIMESTAMP
returns the current server date and time in the session time zone. The default is 3 decimals, i.e. milliseconds precision.
LOCALTIMESTAMP
was introduced in Firebird 3.0.4 and Firebird 2.5.9 as a synonym ofCURRENT_TIMESTAMP
. In Firebird 4.0,CURRENT_TIMESTAMP
returns a instead of aTIMESTAMP [WITHOUT TIME ZONE]
, whileLOCALTIMESTAMP
returnsTIMESTAMP [WITHOUT TIME ZONE]
. It is recommended to useLOCALTIMESTAMP
when you do not need time zone information.The default precision of
LOCALTIME
is 0 decimals, soLOCALTIMESTAMP
is not the exact sum ofCURRENT_DATE
and , unless you explicitly specify a precision (i.e.LOCATIME(3)
orLOCALTIMESTAMP(0)
).
select localtimestamp from rdb$database
-- returns e.g. 2008-08-13 14:20:19.6170
select localtimestamp(2) from rdb$database
See also, Section 11.11, LOCALTIME