Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago
Solved

Filter Previous 4 (Working) Mondays

I have a very large table that contains daily 'EffectiveDates' that I'm trying to filter down by only pulling thru the previous 4 Mondays that are also "Working/Business" days.  My query line below only solves for half of what I'm trying to accomplish:

 

= Table.SelectRows(Source, each Date.IsInPreviousNWeeks([EffectiveDate], 4))

EffectiveDate1moRate
5/9/2024.052
5/8/2024.053
5/7/2024.051

 

  • Anonymous it will work all the time not one time, as soon as the data refresh happens you will getmrecent 4 Mondays. Not sure what makes you think it will work only one time . 

4 Replies

  • Anonymous well, you can easily filter on the day of the week which is Monday, and then keep the bottom 4 rows, it will get you going.

    • Anonymous's avatar
      Anonymous
      Not applicable

      parry2k That would work for a "1-time" solution but I'm looking for a dynamic and rolling formula that automatically does that filtering no matter when the report is viewed.

  • Anonymous it will work all the time not one time, as soon as the data refresh happens you will getmrecent 4 Mondays. Not sure what makes you think it will work only one time . 

    • Anonymous's avatar
      Anonymous
      Not applicable

      parry2k Sorry I'm still more of a beginner with PBI so I might just be misunderstanding.  Can you please provide an example of the solution you're proposing?