DATE/TIME/TIMESTAMP data
types. See Date/Time types.
All the following operators and functions return their values without a time zone.
Date/Time Functions
Notes:
NOW()andCURRENT_TIMESTAMP: When using those functions as part of anINSERT/UPDATEcommand, the returned value is converted into the column data type it is writing to. When writing intoTIMEdata type, only the time is written, when writing intoDATEdata type, only the date is written, and when writing toTIMESTAMPdata type, the whole timestamp is written. Note thatNOW()andCURRENT_TIMESTAMPrefer to the time the transaction starts, and not to each statement time inside the transactionDATE_PART()andEXTRACT()provide similar functionality and accept the same set of units. However,DATE_PARTrequires the unit argument to be passed as a string (e.g. ‘YEAR”, ‘day’), whileEXTRACT()also accepts these units as keywords. The following units are supported:
For a
TIMESTAMP object, both the Date and Time units are supported.