Datetime Functions
This page lists DATETIME
functions that are available in the GSQL query language. Every function in this page either takes a DATETIME
object as its argument or return a DATETIME
object.
datetime_add()
Description
Calculates a new DATETIME
from a specified datepart multiplied by a specified amount, added to a specified DATETIME
.INTERVAL
is a keyword that must be exactly entered. time_unit
is one of the keywords YEAR
, MONTH
, DAY
, HOUR
, MINUTE
, or SECOND
.
datetime_diff()
datetime_format()
Parameters
Parameter | Description | Data type |
---|---|---|
|
A |
|
|
A string pattern expressing the format to print
The default value for this parameter is |
|
datetime_sub( )
Description
Calculates a new DATETIME
from a specified datepart multiplied by a specified amount, subtracted from a specified DATETIME
.INTERVAL
is a keyword that must be exactly entered. time_unit
is one of the keywords YEAR
, MONTH
, DAY
, HOUR
, MINUTE
, or SECOND
.