1 Answer
- Newest
- Most votes
- Most comments
0
To convert a "timestamp with time zone" column in UTC to EST while accounting for daylight savings time in Amazon Redshift.
You can also use the AT TIME ZONE function to convert the UTC timestamp to EST:
SELECT column_name AT TIME ZONE 'UTC' AT TIME ZONE 'EST' FROM your_table;
However you should be able to use CONVERT_TIMEZONE function to achieve the same result: I have done some basic testing and got the result below.
answered a year ago
Hi Jackie, neither of these seem to be working correctly. Due to daylight savings time, there should be a 4 hour difference between UTC and EST on April 12, rather than 5. Also, is there any reason you can see for why CONVERT_TIMEZONE would result in the error message I mentioned?
Relevant content
- asked a year ago
- asked 3 years ago
- AWS OFFICIALUpdated 6 months ago
Along with this, in another column, i have to convert a VARCHAR datetime value in EST to a timestamp. Is there a way to convert this while maintaining EST as the time zone for the column, rather than setting the time zone as the default UTC