Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hello,
I have 2 filters (image below) for my table.
However, when both are applied, the table only shows rows that fits filter 1 AND filter 2.
How can I make it so that it shows rows that fit either filter 1 OR filter 2?
Thank you!
Solved! Go to Solution.
Hi , @TTL
According to your description, you want to make your two filter as OR logic.
In the default Filter pane, the default filtering logic is AND. If we want to filter OR for one of our visual objects, we can try to create a metric for inventory to filter.
Here are the steps you can refer to :
(1)This is my test data:
(2)We can create a measure like this:
Measure = var _diff1= MAX('Table'[Diff1])
var _diff2 = MAX('Table'[Diff2])
return
IF( OR( _diff1 <-0.5 || _diff1 >1 , _diff2 <-0.5 || _diff2 >1 ) ,1,0)
Then we can put this measure on the "Filter on this visual" and then we can meet your need.
And you can also replace the "0.5/1" number to the parameter as a slicer to put in , for this you can refer to :
Use parameters to visualize variables - Power BI | Microsoft Learn
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi , @TTL
According to your description, you want to make your two filter as OR logic.
In the default Filter pane, the default filtering logic is AND. If we want to filter OR for one of our visual objects, we can try to create a metric for inventory to filter.
Here are the steps you can refer to :
(1)This is my test data:
(2)We can create a measure like this:
Measure = var _diff1= MAX('Table'[Diff1])
var _diff2 = MAX('Table'[Diff2])
return
IF( OR( _diff1 <-0.5 || _diff1 >1 , _diff2 <-0.5 || _diff2 >1 ) ,1,0)
Then we can put this measure on the "Filter on this visual" and then we can meet your need.
And you can also replace the "0.5/1" number to the parameter as a slicer to put in , for this you can refer to :
Use parameters to visualize variables - Power BI | Microsoft Learn
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Thank you Aniya! Nice Anya icon 😄
If you need OR filters, you can't use the filter pane to acheive that. This article goes into more details on how to use DAX to get OR conditions: https://apexinsights.net/blog/or-xor-slicing
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
107 | |
105 | |
79 | |
69 | |
62 |
User | Count |
---|---|
142 | |
105 | |
103 | |
85 | |
70 |