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
baluk
Frequent Visitor

how to call a column in a slicer

I need a single column in  table by clicking on slicer the column should be change accordingly as per the slicer . How to achieve this please help

 

Thaks in advance

Spoiler
 
 

Capture.JPG

2 ACCEPTED SOLUTIONS
v-juanli-msft
Community Support
Community Support

Hi @baluk 

Create a measure

Measure =
SWITCH (
    SELECTEDVALUE ( Display[Display] ),
    "Hour", FORMAT ( MAX ( 'Table'[hour] ), "standard" ),
    "Lasthour", FORMAT ( MAX ( 'Table'[lasthour] ), "standard" ),
    "Today", FORMAT ( MAX ( 'Table'[today] ), "General Date" ),
    "Yesterday", FORMAT ( MAX ( 'Table'[yearterday] ), "General Date" )
)

Capture6.JPGCapture7.JPG

Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
v-juanli-msft
Community Support
Community Support

Hi @baluk 

Create a measure

Measure =
SWITCH (
    SELECTEDVALUE ( Display[Display] ),
    "Hour", FORMAT ( MAX ( 'Table'[hour] ), "standard" ),
    "Lasthour", FORMAT ( MAX ( 'Table'[lasthour] ), "standard" ),
    "Today", FORMAT ( MAX ( 'Table'[today] ), "General Date" ),
    "Yesterday", FORMAT ( MAX ( 'Table'[yearterday] ), "General Date" )
)

Capture6.JPGCapture7.JPG

Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

@baluk ,

 

You need to unpivot your columns and take this columns in slicer to get your desired result. I tried to replica your scenario at my side and attched screen shot for your reference. 

Capture.JPG

Do let me know it whether it is what exactly you wanna achieve or not.

 

Don't forget to hit Thumbs up and accept this as a solution if you find it helpful! 

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

Please take a quick glance at newly created dashboards : Restaurant Management Dashboard , HR Analytics Report , Hotel Management Report, Sales Analysis Report , Fortune 500 Companies Analysis , Revenue Tracking Dashboard

@v-juanli-msft please share the PBIX file

 

Thanks

Hi

pbix

amitchandak
Super User
Super User

Try

 

New Col =

Var _sel = selectedvalue(Display)

return

if(_sel = "hour",<>,if(_sel="Month"),<>,<>)

 

 

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.