Documentation
-
Date.StartOfMonth - PowerQuery M
Learn more about: Date.StartOfMonth
-
Learn more about: Date.AddMonths
-
Date.DaysInMonth - PowerQuery M
Learn more about: Date.DaysInMonth
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Date.EndOfMonth(dateTime as any) as any
Returns the end of the month that contains dateTime
.
dateTime
: A date
, datetime
, or datetimezone
value from which the end of the month is calculated.Get the end of the month for 5/14/2011.
Usage
Date.EndOfMonth(#date(2011, 5, 14))
Output
#date(2011, 5, 31)
Get the end of the month for 5/17/2011 05:00:00 PM -7:00.
Usage
Date.EndOfMonth(#datetimezone(2011, 5, 17, 5, 0, 0, -7, 0))
Output
#datetimezone(2011, 5, 31, 23, 59, 59.9999999, -7, 0)
Documentation
Date.StartOfMonth - PowerQuery M
Learn more about: Date.StartOfMonth
Learn more about: Date.AddMonths
Date.DaysInMonth - PowerQuery M
Learn more about: Date.DaysInMonth