yearmonth
To return the month and the year of a given date value
You will get the year and month from a given date value displayed in the format “YYYY/MM”. This can help you filtering, sorting, and grouping records.
If you use the function for an appointment field, Ninox returns the start date of this appointment. If you need the end date of an appointment specify with endof()
.
Syntax
yearmonth(appointment)
yearmonth(date)
yearmonth(timestamp)
Return
string
Examples
yearmonth(myAppointment)
To return the month and the year of a given date value, e.g. 2021/08.
Result: 2021/06
(Appointment =
06/01/2021 09:00 – 06/16/2022 09:00 (US)
01/06/2021 09:00 – 15/06/2022 09:00 (UK))
Result: 2022/06
(with Appointment =
06/01/2021 09:00 – 06/16/2022 09:00 (US)
01/06/2021 09:00 – 15/06/2022 09:00 (UK))
yearmonth(myDate)
To return the month and year of a given date, e.g. 2021/08.
yearmonth(datetime)
To return the month and year of a given timestamp, e.g. 2021/08.
See also
yearweek
, which returns the week and the year of a given date value.
yearquarter
, which returns the quarter and the year of a given date value.
Last updated