Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
Anonymous
Not applicable

Slicer filter multiple columns in a table

I have created a Slicer to control/filter a table.  

i have a table like below, and i use column Measure in the slicer
chriscg28_0-1639446097889.png
  chriscg28_1-1639446178520.png

 

then i created a measure like below, and i use this measure in the table visual.  but it only filter one column at a time.  how do i change the dax in order to enable the multiple filter.

 

Slicer selection =
VAR MySelection =
SELECTEDVALUE('Disconnect table'[Measure], 'RDS_FL_FILE'[Total_ep])
RETUrn
SWITCH(
TRUE(),
MySelection = "Total EP", [Total_ep],
MySelection = "%EP", [%EP],
MySelection = "Total ECY", [Total_ecy],
MySelection = "%ECY", [%ECY],
[Total_ep])

 

as you can see, two values were selected in the slicer, but the table only shows one column.  how do i edit the dax to enable multiple value return?  Thank you!

chriscg28_3-1639446545085.png

 


 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

4 REPLIES 4
OwenAuger
Super User
Super User

Hi @Anonymous 

If you want to see a similar layout but with a column for each "Measure" selected, I would suggest you switch to a Matrix visual, and place "Measure" in the Columns field well.

 

Does that work?

 

Regards,

Owen

 

 


Owen Auger
Did I answer your question? Mark my post as a solution!
Blog
Twitter
LinkedIn
Anonymous
Not applicable

Unfortunately switching to matrix didn't work.  I think the DAX needs work, SELECTEDVALUE only return one value, but I don't know how. 

amitchandak
Super User
Super User

@Anonymous , That is possible using calculation groups, you need external tool for that
https://www.sqlbi.com/blog/marco/2020/07/15/creating-calculation-groups-in-power-bi-desktop/

Anonymous
Not applicable

Thank you.  I'll look into it and see if it fits what I try to accomplish. 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.