Skip to content

Commit

Permalink
Update scalar functions doc for extract/datepart (#8682)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jefffrey authored Jan 1, 2024
1 parent 8ae7ddc commit 4dcfd7d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/source/user-guide/sql/scalar_functions.md
Original file line number Diff line number Diff line change
Expand Up @@ -1410,6 +1410,7 @@ date_part(part, expression)
The following date parts are supported:

- year
- quarter _(emits value in inclusive range [1, 4] based on which quartile of the year the date is in)_
- month
- week _(week of the year)_
- day _(day of the month)_
Expand All @@ -1421,6 +1422,7 @@ date_part(part, expression)
- nanosecond
- dow _(day of the week)_
- doy _(day of the year)_
- epoch _(seconds since Unix epoch)_

- **expression**: Time expression to operate on.
Can be a constant, column, or function.
Expand Down Expand Up @@ -1448,6 +1450,7 @@ extract(field FROM source)
The following date fields are supported:

- year
- quarter _(emits value in inclusive range [1, 4] based on which quartile of the year the date is in)_
- month
- week _(week of the year)_
- day _(day of the month)_
Expand All @@ -1459,6 +1462,7 @@ extract(field FROM source)
- nanosecond
- dow _(day of the week)_
- doy _(day of the year)_
- epoch _(seconds since Unix epoch)_

- **source**: Source time expression to operate on.
Can be a constant, column, or function.
Expand Down

0 comments on commit 4dcfd7d

Please sign in to comment.