Forum Discussion
Ignoring external date filter
Hello,
I have the measure 'Unpaid Full Invoice Amount TREATAS', but I can't get it to return a result such that if I apply an external filter for January 2024, the visualization displays all values from January 31, 2025 to January 1, 2024. Do you have any suggestions on how to resolve this?
Skolu ataskaita VIG 2025 NEW4 - TEST2.pbix
Arturas
Hi,
I have solved a similar question in the attached PBI file.
6 Replies
- rohit1991Super User
Hi Sarutra
To ignore an external date slicer and always return values from a specific fixed range say from January 1, 2024 to January 31, 2025, regardless of any user-applied filters you'll need to build a measure that explicitly overrides the filter context.
You can write this DAX measure :
FixedDateTotal = CALCULATE ( SUM ( 'Invoice'[Amount] ), REMOVEFILTERS ( 'Date'[Date] ), 'Date'[Date] >= DATE (2024, 1, 1) && 'Date'[Date] <= DATE (2025, 1, 31) )You can try these steps:
-
REMOVEFILTERS('Date'[Date]) clears any external slicer or visual filter on the date field.
-
The date range condition inside CALCULATE then reapplies a fixed filter from 2024-01-01 to 2025-01-31.
-
This ensures the measure always returns values for your desired date window even if the report user filters to something else like 2023 or 2026.
-
- SarutraHelper I
Thank you for the answer. I tried various ways to remove the external date filter, but I wasn’t able to get the correct result. Could you please provide a DAX example? I want to remind you that the goal is: if the external filter is set to 2025-01, I need to get results from 2025-01-31 to 2024-01-01, and if the filter is set to 2024-12, I need to get results from 2024-12-31 to 2024-01-01.
arturas
- Ashish_MathurSuper User
Hi,
I have solved a similar question in the attached PBI file.
- v-echaithraCommunity Support
Hi Sarutra ,
As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided for the issue worked? or Let us know if you need any further assistance?
If our response addressed, please mark it as Accept as solution and click Yes if you found it helpful.Regards,
Chaithra E. - v-echaithraCommunity Support
Hi Sarutra ,
We wanted to kindly follow up to check if the solution provided for the issue worked? or Let us know if you need any further assistance?
If our response addressed, please mark it as Accept as solution and click Yes if you found it helpful.Regards,
Chaithra E. - v-echaithraCommunity Support
Hi @Sarutra ,
As we haven’t heard back from you, we wanted to kindly follow up to check if the solution provided for the issue worked? or Let us know if you need any further assistance?
If our response addressed, please mark it as Accept as solution and click Yes if you found it helpful.Regards,
Chaithra E.