to_date

description

Syntax

DATE TO_DATE(DATETIME datetime)

to_date returns the date value from DATETIME type.

example

MySQL > select to_date("2020-02-02 00:00:00");
+--------------------------------+
| to_date('2020-02-02 00:00:00') |
+--------------------------------+
| 2020-02-02                     |
+--------------------------------+

keyword

TO_DATE