CONVERT_TZ(dt,from_tz,to_tz) : CONVERT_TZ « Date Time Functions « MySQL Tutorial





CONVERT_TZ() converts a datetime value dt from the time zone given by from_tz to the time zone given by to_tz and returns the resulting value.

CONVERT_TZ() returns NULL if the arguments are invalid.

mysql>
mysql> SELECT CONVERT_TZ('2004-01-01 12:00:00','GMT','MET');
+-----------------------------------------------+
| CONVERT_TZ('2004-01-01 12:00:00','GMT','MET') |
+-----------------------------------------------+
| NULL                                          |
+-----------------------------------------------+
1 row in set (0.02 sec)










14.4.CONVERT_TZ
14.4.1.CONVERT_TZ(dt,from_tz,to_tz)
14.4.2.SELECT CONVERT_TZ('2004-01-01 12:00:00','+00:00','+10:00');