Forum Discussion
Power BI Filter a Table Visual
Hello everyone,
Hope you are doing good.
I need help with filtering on a table visual.
The sample data would be like this-
| Order No. | Condition1 | Condition2 | Condition3 | Customer No. | Amount | Location |
| 123 | 1 | A | X | A1 | 1000 | Houston |
| 234 | 0 | A | Y | A1 | 1000 | Houston |
| 345 | 1 | B | Z | A2 | 3000 | California |
| 456 | 0 | C | Z | A2 | 2000 | California |
I need multiple filters which filter the table visual based on multiple conditions.
For eg-
Filter1 should return the Order No. with Condition1=1 AND Condition2=A AND Condition3=X.
Filter2 returns the Order No. with Condition1=0 AND Condition2=A AND Condition3=X.
Filter3 returns orders with the Order No. with Condition3=Z.
Similarly I need 10 filters that would filter a table visual with order details like-
| Order No. | Customer No. | Amount | Location |
| 123 | A1 | 1000 | Houston |
| 234 | A1 | 1000 | Houston |
| 456 | A2 | 2000 | California |
When I select Filter1, the table should show only order details for Order No.=123.
When I select Filter2, the table shows no values.
When I select Filter3, the table should show orders with Order No. =345,456
When I select Filter1 and Filter3, the table shows orders with Order No. = 123,345,456
What would be the best approach to solve this?
Thanks in advance
Akshay
you can create a column
Column =switch(TRUE(),'Table'[Condition1]=1 && 'Table'[Condition2]="A" && 'Table'[Condition3]="X","filter1",'Table'[Condition1]=0&&'Table'[Condition2]="A" &&'Table'[Condition3]="X","filter2",'Table'[Condition3]="Z", "filter3")and create a filter table for selection.pls see the attachment below- Anonymous1 year ago
Hi AksPRAKSH
Thanks to ryan_mayu for the quick reply!
In addition to ryan_mayu's method, you can also create hierarchical slicers that put multiple filter criteria into one slicer.
Right-click on “Condition1” and select “Create hierarchy”, then add “Condition2” and “Condition3” to this hierarchy.
Create a slicer with the hierarchy and use “CTRL” + click for multi-criteria filtering.
Best Regards,
Jarvis Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
2 Replies
- AnonymousNot applicable
Hi AksPRAKSH
Thanks to ryan_mayu for the quick reply!
In addition to ryan_mayu's method, you can also create hierarchical slicers that put multiple filter criteria into one slicer.
Right-click on “Condition1” and select “Create hierarchy”, then add “Condition2” and “Condition3” to this hierarchy.
Create a slicer with the hierarchy and use “CTRL” + click for multi-criteria filtering.
Best Regards,
Jarvis Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. - ryan_mayuSuper User
you can create a column
Column =switch(TRUE(),'Table'[Condition1]=1 && 'Table'[Condition2]="A" && 'Table'[Condition3]="X","filter1",'Table'[Condition1]=0&&'Table'[Condition2]="A" &&'Table'[Condition3]="X","filter2",'Table'[Condition3]="Z", "filter3")and create a filter table for selection.pls see the attachment below