mysql from_timestamp(0) does not match my current time

Viewed 98

My timezone is UTC+8, but when I run

mysql> select from_unixtime(0);
+---------------------+
| from_unixtime(0)    |
+---------------------+
| 1970-01-01 07:30:00 |
+---------------------+

I got "1970-01-01 07:30:00" instead of "1970-01-01 08:00:00".

I ran:

show variables like "%time_zone%";  

Then I got:

system_time_zone    +08  
time_zone           SYSTEM  
1 Answers
Related