Skip to content

Commit

Permalink
Minor: Document third argument of date_bin as optional and default …
Browse files Browse the repository at this point in the history
…value (#8912)

* Minor: Document third argument of date_bin as optional

# Rationale
@mhilton  noticed this as part of an internal discussion where we were confused about the output values of `date_bin` for timestamps with timezones (as the default argument is for the unix EPOCH in UTC)

# Changes:
Document the third parameter to `date_bin` better

* prettier
  • Loading branch information
alamb committed Jan 20, 2024
1 parent e7c0482 commit a4a9429
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion docs/source/user-guide/sql/scalar_functions.md
Original file line number Diff line number Diff line change
Expand Up @@ -1347,7 +1347,8 @@ date_bin(interval, expression, origin-timestamp)
- **interval**: Bin interval.
- **expression**: Time expression to operate on.
Can be a constant, column, or function.
- **timestamp**: Starting point used to determine bin boundaries.
- **origin-timestamp**: Optional. Starting point used to determine bin boundaries. If not specified
defaults `1970-01-01T00:00:00Z` (the UNIX epoch in UTC).

The following intervals are supported:

Expand Down

0 comments on commit a4a9429

Please sign in to comment.