DATE_TRUNC (Lakehouse v2)
Truncates a date or datetime value to the specified precision.
Analyze Syntax
Section titled “Analyze Syntax”func.date_trunc(<unit>, <datetime>)Analyze Examples
Section titled “Analyze Examples”func.date_trunc('MONTH', '2024-06-15')
┌──────────────┐│ '2024-06-01' │└──────────────┘SQL Syntax
Section titled “SQL Syntax”DATE_TRUNC(<unit>, <datetime>)SQL Examples
Section titled “SQL Examples”SELECT DATE_TRUNC('MONTH', '2024-06-15');
┌────────────┐│ 2024-06-01 │└────────────┘