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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Creating measure to show all values that I am filtered on.

I am using the code. Current Sku/Description =
IF (
    ISFILTERED ( TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description] ),
    FIRSTNONBLANK (
        TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description],
        TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description]
    ),
    ""
)

 

This creates a measure that shows on a card only the selected filter for the column SKU/Material Desription. 

Slatesh_1-1643666369429.png

 

Slatesh_0-1643666318206.png

 

But what I need help with is having the card show multiple filter selections. Instead of just the first non-blank filter selection. 

When I select two items to filter on, I only see the first non-blank value. I want to see all values I have filtered on. 

Slatesh_2-1643666441708.png

Slatesh_3-1643666451021.png

 

 

1 ACCEPTED SOLUTION

@Anonymous 

OK.  if you're not using a dimension table then you can use VALUES to get items listed once.

Selected = 
IF(
    ISFILTERED(TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description]), 
    CONCATENATEX(VALUES(TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description]), TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description], ", ") 
)

View solution in original post

5 REPLIES 5
Anonymous
Not applicable

When multiple filters were selected the statement you gave resulted in the same value over and over again.

Slatesh_0-1643743099317.png

 

@Anonymous 

OK.  if you're not using a dimension table then you can use VALUES to get items listed once.

Selected = 
IF(
    ISFILTERED(TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description]), 
    CONCATENATEX(VALUES(TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description]), TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description], ", ") 
)
PaulOlding
Solution Sage
Solution Sage

Hi @Anonymous 

You could use CONCATENATEX to build a list of selected values

Selected = 
IF(
    ISFILTERED(TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description]), 
    CONCATENATEX(TRPT_FS_COPA_ADHOC_DTL_V2, TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description], ", ") 
)
Anonymous
Not applicable

A table would do, except I need the card or visual to be blank if no filters are selected. But I also need to be able to show all filters.

Card is blank with no filters selected.

Slatesh_0-1643724965973.png

With one filter selected is shows the filter. 

Slatesh_1-1643724989521.png

With more than one filter selected is shows this:

Slatesh_2-1643725013935.png

I need the visual to be blank if nothing is selected. But show every filter that is selected. 

VahidDM
Super User
Super User

Hi @Anonymous 

 

You can just add  TRPT_FS_COPA_ADHOC_DTL_V2[SKU/Material Description] to the table and then use filter pane rather than using codes. If I did not get your point correctly, Can you please add more details and make your question more clear.

 

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
LinkedIn: 
www.linkedin.com/in/vahid-dm/

 

 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.