Forum Discussion
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))
| EffectiveDate | 1moRate |
| 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
- parry2k
Super User
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.
- AnonymousNot 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.
- parry2k
Super User
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 .
- AnonymousNot 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?