Oracle® OLAP Expression Syntax Reference Release 11.2 Part Number E23381-01 |
|
|
PDF · Mobi · ePub |
TO_TIMESTAMP_TZ
converts a text expression to a value of TIMESTAMP
WITH
TIME
ZONE
data type.
TIMESTAMP WITH TIME ZONE
TO_TIMESTAMP_TZ(char [, fmt [ 'nlsparam' ] ])
char
is a text expression to be converted.
fmt
is a datetime model format specifying the format of char
. The default date format is determined implicitly by the NLS_TERRITORY
initialization parameter or can be set explicitly by the NLS_DATE_FORMAT
parameter. For data type formats, refer to the Oracle Database SQL Language Reference.
nlsparam
specifies the language in which month and day names and abbreviations given in char
. This argument has this form:
'NLS_DATE_LANGUAGE = language'
By default, char
is in the session date language.
TO_TIMESTAMP_TZ('2006-03-26 7:33:00 -4:00', 'YYYY-MM-DD HH:MI:SS TZH:TZM')
returns the value 26-MAR-06 07.33.00.000000 AM -04:00
.
TO_TIMESTAMP_TZ('2006-AGOSTO-13 7:33:00 -4:00', 'YYYY-MONTH-DD HH:MI:SS TZH:TZM', 'NLS_DATE_LANGUAGE=SPANISH')
returns the value 13-AUG-06 07.33.00.000000 AM -04:00
.