Important

Helios features are now enabled during weekly update windows and are no longer directly tied to SingleStore engine releases. Refer to the release notes to view the latest features available in your Helios cluster.

UTC_TIMESTAMP

The UTC_TIMESTAMP() function returns the current time, in the UTC time zone.

Syntax

UTC_TIMESTAMP()

Return Type

Datetime object.

Examples

You can specify a precision of 0 (the default) or 6 digits for the fraction of seconds.

SELECT UTC_TIMESTAMP();
+---------------------+
| UTC_TIMESTAMP()     |
+---------------------+
| 2022-01-10 13:10:06 |
+---------------------+
SELECT UTC_TIMESTAMP(0);
+---------------------+
| UTC_TIMESTAMP(0)    |
+---------------------+
| 2022-01-10 13:10:09 |
+---------------------+
1 row in set (0.084 sec)
SELECT UTC_TIMESTAMP(6);
+----------------------------+
| UTC_TIMESTAMP(6)           |
+----------------------------+
| 2022-01-10 13:10:12.113996 |
+----------------------------+
1 row in set (0.001 sec)

Related Topics

Last modified:

Was this article helpful?