Date.IsInNextWeek

Updated on

Date.IsInNextWeek is a Power Query M function that indicates whether the given date(time) value occurs during the next week, as determined by the system. The function returns a boolean value (true or false).

Compatible with: Power BI Service Power BI Desktop Excel Microsoft 365

Syntax

Date.IsInNextWeek( dateTime as any ) as nullable logical

Description

Date.IsInNextWeek assesses if dateTime (of type date, datetime, or datetimezone) falls within the upcoming week, based on the current system date and time, excluding current week values.

Examples

Determine if the week after the current system time is in the next week.

// Output: true
Date.IsInNextWeek( Date.AddDays( DateTime.FixedLocalNow(), 7 ) )

Other functions related to Date.IsInNextWeek are:

BI Gorilla Blog

Contribute » | Contributors: Rick de Groot
Microsoft documentation: https://learn.microsoft.com/en-us/powerquery-m/date-isinnextweek