Date.IsInPreviousNQuarters
This function determines if the provided date and time value, dateTime, falls within the previous number of quarters based on the current date and time on the system. It should be noted that the funct...
This function determines if the provided date and time value, dateTime, falls within the previous number of quarters based on the current date and time on the system. It should be noted that the function will return a false result if the value falls within the current quarter.
Inputs:
- dateTime: A date, datetime, or datetimezone value that needs to be checked.
- quarters: The number of quarters back to evaluate against.
Check if the quarter before the current time is within the last two quarters. To do this, use the Power Query function MDate.IsInPreviousNQuarters and provide the current date subtracted by one quarter as the input, along with the number 2 to indicate the previous two quarters. The output will be true if the quarter falls within the specified range.