Purpose
This function returns the standard UTC time corresponding to the specified time from a datetime value with a time zone offset. If no time zone is specified, the specified datetime is associated with the current session time zone.
Note
UTC (Universal Time Coordinated) is coordinated universal time. UTC is the same as Greenwich Mean Time (GMT), which is the same as the local time in London, UK.
Syntax
SYS_EXTRACT_UTC (datetime_with_timezone)
Parameters
datetime_with_timezone is a value of the TIMESTAMP WITH TIME ZONE or TIMESTAMP WITH LOCAL TIME ZONE data type.
Return type
TIMESTAMP
Examples
Return the standard UTC time for 2021-11-18 10:08:08.18 +08:00.
obclient> SELECT SYS_EXTRACT_UTC(TIMESTAMP '2021-11-18 10:08:08.18 +08:00') "SYS_EXTRACT_UTC" FROM DUAL;
+---------------------------------+
| SYS_EXTRACT_UTC |
+---------------------------------+
| 18-NOV-21 02.08.08.180000000 AM |
+---------------------------------+
1 row in set
