This works, but is not ideal as I have to describe ALL the filter columns I will accept (FilterColumn1-N). And there are many "external" slicers and visuals that filter many columns in my PBI report.
What I really need is a similar DAX function like ALLEXCEPT that just removes ONE filter column, but keep all the others.
It seems like a logical DAX function, but I could not find it.
Can anybody help me here?
Thanks,
Lars
Solved! Go to Solution.
Thanks to both of you for your suggestions.
It took me another four hours to get to the solution, as REMOVEFILTERS or ALL where not usable in my DAX context.
But I found the solution for me was to use this DAX measure (pseudo code):
Measure1 = CALCULATE([Value], CALCULATETABLE(ALLSELECTED(Data), REMOVEFILTERS(Data[FilterColumnToRemove])))
This is much simpler than what I have use before and works with external filters and filters in the context of the visual in use.
Thanks,
Lars
ALL used as a CALCULATE modifier does exactly that. And by the way, ALL in this role is totally equivalent to REMOVEFILTERS.
removefilters allows to remove the filter on one specific column. I have the impression that the question is:
"removes ONE filter column, but keep all the others."
Although that is not what ALLExcept does, allexcept removes all filters except one:
"A table with all filters removed except for the filters on the specified columns." - https://docs.microsoft.com/nl-nl/dax/allexcept-function-dax
Proud to be a Super User!
Awesome Keyboard Shortcusts in Power BI, thumbs up if you like the article
My Community Blog Articles (check them out!)
My Blog - Power M code to automatically detect column types -
How to create test data using DAX!
Thanks to both of you for your suggestions.
It took me another four hours to get to the solution, as REMOVEFILTERS or ALL where not usable in my DAX context.
But I found the solution for me was to use this DAX measure (pseudo code):
Measure1 = CALCULATE([Value], CALCULATETABLE(ALLSELECTED(Data), REMOVEFILTERS(Data[FilterColumnToRemove])))
This is much simpler than what I have use before and works with external filters and filters in the context of the visual in use.
Thanks,
Lars
Hi Lars, Thank you for this solution you saved my life.
In your pseudo code you are using removefilters?
Proud to be a Super User!
Awesome Keyboard Shortcusts in Power BI, thumbs up if you like the article
My Community Blog Articles (check them out!)
My Blog - Power M code to automatically detect column types -
How to create test data using DAX!
Removefilters(
https://docs.microsoft.com/nl-nl/dax/removefilters-function-dax
Proud to be a Super User!
Awesome Keyboard Shortcusts in Power BI, thumbs up if you like the article
My Community Blog Articles (check them out!)
My Blog - Power M code to automatically detect column types -
How to create test data using DAX!
Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!