SUBTRACT_TIME_ZONE_OFFSET
Subtracts a timezone offset from a date.
The timezone offset can be any standard format accepted by Java's ZoneId.of
method (America/New_York, +02:00, etc.)
Syntax
Arguments
Name
Type
Description
Default Value
time
timestamp
zone
string
Returns
timestamp
Examples
time
zone
Output
timestamp '2018-03-10 08:55:12.456'
'+02:00'
timestamp '2018-03-10 06:55:12.456'
timestamp '2018-03-10 08:55:12.456'
'America/New_York'
timestamp '2018-03-10 13:55:12.456'
timestamp '2018-03-10 08:55:12.456'
''
null
timestamp '2018-03-10 08:55:12.456'
'Invalid Zone Id'
null
Transformation job example
SQL
Query result
time
zone
Output
timestamp '2018-03-10 08:55:12.456'
'+02:00'
timestamp '2018-03-10 06:55:12.456'
Last updated