Get started
Load & manage data
Work with data
Administration
Reference & resources
CLUSTER BY
mask
ROW FILTER
Updated Dec 26, 2024
Send us feedback
day
Applies to: Databricks SQL Databricks Runtime
Returns the day of month of the date or timestamp. This function is a synonym for extract(DAY FROM expr).
extract(DAY FROM expr)
day(expr)
expr: A DATE or TIMESTAMP expression.
expr
DATE
TIMESTAMP
An INTEGER.
INTEGER
> SELECT day('2009-07-30'); 30
dayname function
dayofmonth function
dayofweek function
dayofyear function
hour function
minute function
second function
extract function