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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Danny_Stultiens
Frequent Visitor

Measure "If filter = (All) then show "All" else show filter value"

Hi people,

 

For a report that is used by different production plants, I'm able to filter pages per site (with bookmarks). I have a card in the page that shows the current filtered plant name by showing the field value "First [Plant]".


Some users want to see the page showing data from all plants combined. When I remove the filter on plant to show all plants, all values on the page show the correct data, but the card with the plant name shows the first plant name alphabetically (of course). 

 

I would like to use a measure that shows the plant name if the filter is active, and shows the value "All" if the filter is inactive, showing all plants combined. I was trying with the if function and searched the forum, but unfortunatly did not find the exact answer I'm looking for.

Can someone please push me in the right direction? Thanks a lot in advance!

 

With kind regards,

 

Danny

2 ACCEPTED SOLUTIONS
Anonymous
Not applicable

Hey @Danny_Stultiens 

The measure that you are using in card visual can be something like this to fullfil your requirement:

FilteredValue =
IF (
ISCROSSFILTERED ( 'First [Plant]' ),
SELECTEDVALUE ( 'First [Plant]' ),
"ALL"
)

 

 

Please accept it as a solution if it matches your requirement🙂

View solution in original post

Anonymous
Not applicable

Hey @Danny_Stultiens 

The measure that you are using in card visual can be something like this to fullfil your requirement:

FilteredValue =
IF (
ISCROSSFILTERED ( 'First [Plant]' ),
SELECTEDVALUE ( 'First [Plant]' ),
"ALL"
)

 

 

Please accept it as a solution if it matches your requirement🙂

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Hey @Danny_Stultiens 

The measure that you are using in card visual can be something like this to fullfil your requirement:

FilteredValue =
IF (
ISCROSSFILTERED ( 'First [Plant]' ),
SELECTEDVALUE ( 'First [Plant]' ),
"ALL"
)

 

 

Please accept it as a solution if it matches your requirement🙂

Thank you for your quick reply.

Exactly what I was looking for! Works like a charm.

 

 

Anonymous
Not applicable

Hey @Danny_Stultiens 

The measure that you are using in card visual can be something like this to fullfil your requirement:

FilteredValue =
IF (
ISCROSSFILTERED ( 'First [Plant]' ),
SELECTEDVALUE ( 'First [Plant]' ),
"ALL"
)

 

 

Please accept it as a solution if it matches your requirement🙂

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.