UTC_DATE()
This page is part of MariaDB's Documentation.
The parent of this page is: Functions for MariaDB Xpand
Topics on this page:
Overview
Returns the current date in the UTC timezone.
USAGE
UTC_DATE()
DETAILS
UTC_DATE()
is a date-time function that returns the current date in the UTC timezone (Coordinated Universal Time).
When called in string context, the return value is formatted as YYYY-MM-DD
.
When called in numeric context, the return value is formatted as YYYYMMDD
.
See CURDATE() for an equivalent function using the currently active timezone.
EXAMPLES
SELECT UTC_DATE();
+------------+
| UTC_DATE() |
+------------+
| 2020-11-06 |
+------------+
SELECT UTC_DATE()+0;
+--------------+
| UTC_DATE()+0 |
+--------------+
| 20201106 |
+--------------+