The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hello to all,
I have a problem with my filter. When I filter on a category, I should have only three people concerned. It works well if in my table I use their own fields. The problem is that when I add fields calculated from measurements in my table, the context of the filter disappears.
In the picture, the top table shows the expected result. It works because I did not add my measure. When I add my measure, the filter by category does not work anymore. I imagine that the ALLEXCEPT function can help me but I can't place it in my measure.
1 Cumulative Buyer/Appro STD = if(CALCULATE([Number of purchases],FILTER('NOHA PURCHASES','NOHA PURCHASES'[Buyer (order)]="X"), FILTER('NOHA CFO','NOHA CFO'[Approval WF Standard]="X"))>=1, "CUMULARITY DECREASED", "CLEAR")
If someone knows how to help me I thank him/her greatly.
Solved! Go to Solution.
@Anonymous
You can add the Allexcept() function in the bold part but you should use Filter(All(table), [Category]=MAX([Category]). So try:
1 Cumulative Buyer/Appro STD = if(CALCULATE([Number of purchases],FILTER('NOHA PURCHASES','NOHA PURCHASES'[Buyer (order)]="X"), FILTER('NOHA CFO','NOHA CFO'[Approval WF Standard]="X"), Filter(All('Tablename'),[Category]=MAX([Category])))>=1, "CUMULARITY DECREASED", "CLEAR")
Paul Zheng _ Community Support Team
If this post helps, please Accept it as the solution to help the other members find it more quickly.
@Anonymous
You can add the Allexcept() function in the bold part but you should use Filter(All(table), [Category]=MAX([Category]). So try:
1 Cumulative Buyer/Appro STD = if(CALCULATE([Number of purchases],FILTER('NOHA PURCHASES','NOHA PURCHASES'[Buyer (order)]="X"), FILTER('NOHA CFO','NOHA CFO'[Approval WF Standard]="X"), Filter(All('Tablename'),[Category]=MAX([Category])))>=1, "CUMULARITY DECREASED", "CLEAR")
Paul Zheng _ Community Support Team
If this post helps, please Accept it as the solution to help the other members find it more quickly.
Did you see that they simplified the behavior of the CALCULATE() command for scenarios like yours?
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the August 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
76 | |
65 | |
52 | |
51 |
User | Count |
---|---|
128 | |
117 | |
78 | |
65 | |
63 |