FROM_TZ function in Oracle

FROM_TZ is one of the vital Conversion functions of Oracle. It is used to convert a TIMESTAMP value to a TIMESTAMP WITH TIME ZONE value. The FROM_TZ function is supported in the various versions of the Oracle/PLSQL, including, Oracle 12c, Oracle 11g, Oracle 10g and Oracle 9i.


FROM_TZ ( timestamp_value, time_zone_value)

timestamp_value: It is used to specify the timestamp value to be converted.
time_zone_value: It is used to specify the time zone value to be used for conversion.


select FROM_TZ(TIMESTAMP '2019-06-26 02:20:42', '-2:00')
from dual;


26-Jun-19 AM -02:00

The TIMESTAMP WITH TIME ZONE value is the result.

Please Share