Jump to: navigation, search

Mysql UTC TIMESTAMP

From w3cyberlearnings

Contents

MySQL UTC_TIMESTAMP Function

This function returns the UTC date and time as in 'YYYY-MM-DD HH:MM:SS' or YYYYMMDDHHMMSS.uuuuuu format.

Syntax UTC_TIMESTAMP

UTC_TIMESTAMP();

Example 1


mysql> SELECT UTC_TIMESTAMP();
+---------------------+
| UTC_TIMESTAMP()     |
+---------------------+
| 2012-05-24 13:39:30 |
+---------------------+
1 row in set (0.00 sec)

Example 2

mysql> SELECT UTC_TIMESTAMP()+0;
+-----------------------+
| UTC_TIMESTAMP()+0     |
+-----------------------+
| 20120524133926.000000 |
+-----------------------+
1 row in set (0.00 sec)

Related Links



Navigation
Web
SQL
MISC
References