TIMESTAMP WITH LOCAL TIME ZONE Data Type
Description
It differs from TIMESTAMP WITH TIME ZONE in that data stored in the database is normalized to the database time zone, and the time zone information is not stored as part of the column data..(Oracle SQL Language Reference Timestamp with Local Time Zone Data Type)
The Snowflake equivalent is TIMESTAMP_LTZ.
For more information, see also the TIMESTAMP section.
Sample Source Patterns
Timestamp with Time Zone in Create Table
Oracle
Snowflake
Retrieving data from a Timestamp with Local Time Zone column
Oracle
Snowflake
Note that the results are different in both engines because each database is set with a different time zone. The Oracle timezone is '+00:00' and the Snowflake timezone is 'America/Los_Angeles'.
Use the following syntax to change the default timezone of the database:
Known Issues
1. Default database timezone
The operations with this kind of data type will be affected by the database timezone, the results may be different. You can check the default timezone using the following queries:
Oracle
Snowflake
2. Oracle Timestamp with local timezone behavior
When operating timestamps with local timezone data types, Oracle converts the timestamps to the default timezone of the database. In order to emulate this behavior in Snowflake, the TIMESTAMP_TYPE_MAPPING session parameter should be set to 'TIMESTAMP_LTZ'.
3. Timestamp formats may be different
Snow Convert does not perform any conversion for the date/timestamps format strings, so there may be errors when deploying the code. Example:
Oracle
Snowflake
The query will fail in Snowflake because the default timestamp input format does not recognize '-8:00' as a valid UTC offset. It should be replaced with '0800' or '-08:00' in order to get the same result.
Related EWIs
No related EWIs.
Last updated