LastDay
The LastDay function evaluates a specified date component (i.e., year, quarter, month, or week) in a date value and returns the last date and time in that component as a timestamp.
Syntax
LastDay(date, precision)
Function arguments:
- date (required) - the date or column containing date values from which the date component is extracted
- precision (required) - the date component (i.e., year, quarter, month, or week) evaluated for its last date and time
Examples
LastDay([Invoice Date], "month")
Extracts the month component from the date in the Invoice Date column and returns the last date and time for that month.
LastDay(Date("2020-01-10 10:34:29"), “year”)
Extracts the year component from the specified date (January 10, 2020) and returns the last date and time for that year.
Updated 5 months ago
Related resources