Related ABL functions
- Last Updated: January 16, 2024
- 1 minute read
- OpenEdge
- Version 12.8
- Documentation
Related ABL functions
You can use the DATETIME and DATETIME-TZ functions
to create DATETIME and DATETIME-TZ variables
and fields:
-
DATETIME— Creates aDATETIMEfrom date and time values or from a character string. The following example uses theDATETIMEfunction:
|
-
DATETIME-TZ— Creates aDATETIME-TZfrom date, time, and time zone values or from a character string. The following example uses theDATETIME-TZfunction:
|
The ABL functions summarized in the following table support the DATETIME and DATETIME-TZ data
types. For details on each of these functions, see ABL
Reference.
| Function | Description |
|---|---|
ADD-INTERVAL
|
Adds or subtracts a specified unit of time
(days, months, seconds, etc.) to/from a DATETIME or DATETIME-TZ value.
This function takes the date, time, and time zone information into
account. You can also use this function with a DATE. |
DATE
|
Returns the date part of DATETIME or DATETIME-TZ. |
DAY
|
Returns the day of the month of the date part
of the DATETIME or DATETIME-TZ value. |
INTERVAL1
|
Returns an integer that represents an interval
between two date/times, expressed in interval-units (days, months,
seconds, etc.). This function takes the date, time, and time zone
information into account. You can also use this function with a DATE. |
ISO-DATE1
|
Returns the character representation of a DATE, DATETIME or DATETIME-TZ that
conforms to the ISO 8601 standard for date/time representations
- formats are equivalent to the XML Schema date and dateTime formats. |
MONTH
|
Returns an integer value representing the month
of the date part of the DATE, DATETIME,
or DATETIME-TZ value. |
MTIME1
|
Returns an integer representing the time part
of a DATETIME or DATETIME-TZ in
milliseconds. With no arguments, MTIME returns
the number of milliseconds since midnight. |
NOW1
|
Returns the current system date, time, and
time zone as a DATETIME-TZ. If assigned to a DATETIME, NOW does
not include the time zone. |
STRING
|
Converts a value of any data type into a character value. |
TIMEZONE1
|
Returns an integer representing the time zone
of a DATETIME-TZ in minutes. With no arguments, TIMEZONE returns
the current time zone of the session. |
WEEKDAY
|
Returns the weekday of the date part of the DATETIME or DATETIME-TZ value. |
YEAR
|
Returns the year of the date part of the DATETIME or DATETIME-TZ value. |
1 This ABL function is new to OpenEdge Release 10.