It would be extremely helpful to have a built in function to convert a time stamp between time zones using the tz database (more info: https://data.iana.org/time-zones/tz-link.html and https://en.wikipedia.org/wiki/Tz_database). I regularly need to convert time stamps from one time zone to another, but can't simply apply an offset, but it is time consuming to have to look up the offsets to convert the time stamp. Additionally, there is extra work required since certain locations have daylight saving time and others don't, and daylight saving time start/end dates are location specific.
This function could be something like this:
ConvertTimeZone( ts, tzFrom, tzTo ) //ts is the time stamp will be converted from tzFrom to tzTo
//example
ConvertTimeZone( 05May2022:19:31:07, "UTC", "America/Los_Angeles" ) //result: 05May2022:12:31:07
Ideally, all datetime values would be changed to contain the time zone, and be set to default of UTC, if not specified.
Each time zone should use the TZ database name (https://en.wikipedia.org/wiki/List_of_tz_database_time_zones), as is used in other programming languages (e.g.: Python).
Here is a question about this issue: https://community.jmp.com/t5/Discussions/Time-zone-conversion/m-p/331514#M58032
For a very humorous description of the time zone issue, watch this video: https://www.youtube.com/watch?v=-5wpm-gesOY&t=3s. It is 10 minutes long, but well worth the *time* (pardon the pun).
... View more