Extracts the year from a date or datetime.
Accepts Date, NaiveDateTime, or DateTime structs.
Examples
year(date(2024, 6, 15)) → 2024
Extracts the year from a date or datetime.
Accepts Date, NaiveDateTime, or DateTime structs.
year(date(2024, 6, 15)) → 2024