DATE
Descriptionβ
Extracts the date from the datetime.
Syntaxβ
DATE(<datetime>)
Parametersβ
Parameter | Description |
---|---|
<datetime> | A valid date expression |
Return Valueβ
Returns the date part of the datetime.
Examplesβ
select date('2010-12-02 19:28:30');
+----------------------------------------------------+
| date(cast('2010-12-02 19:28:30' as DATETIMEV2(0))) |
+----------------------------------------------------+
| 2010-12-02 |
+----------------------------------------------------+