Details
Description
On Windows, the global variable system_time_zone doesn't properly reflect the used time zone when the environment variable TZ is set.
For example, on my system configured for region Germany, but TZ is set as "CST-8":
SELECT @@time_zone, @@system_time_zone, TIMEDIFF(NOW(), UTC_TIMESTAMP());
SYSTEM Europe/Berlin 08:00:00
Whereas in Linux it returns
SYSTEM CST 08:00:00
Attachments
Issue Links
- is caused by
-
MDEV-19243 Fix timezone handling on Windows to report POSIX timezone names
-
- Closed
-
sweiser a question
From documentation (emphasis mine)
If you are using a Unix-like operating system, then you can set the system time zone by setting the TZ environment variable in your shell before starting the server. For example:
$ export TZ='America/New_York'
$ service mysql start
You are not using Unix-like operating system, why would you expect that to work?