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
Anonymous
Not applicable

Slicer (Measure Count)

Hello Everyone

Could you pls help me?

I have the following table in PowerBi. The "Has Paid?" column is a measure. And I would like to create a slicer which displays

Has paid? 1 or blank to filter the ones which are blank. 

Is there a way to insert this measure into a slicer?

NameAddressHas Paid?total records
xxxxxxyyyyy11
aaaabbbb 1
cccccdddd11
dddddeeee 1
dddddrrrrrr11

 

1 ACCEPTED SOLUTION

Hi  , @Anonymous

Measure  cannot be used in  slicer.It is recommended that you convert the measure into a calculated column and use it as a filter if possible.

 

In addition ,here  is another workaround .
1.Create a seperate table ( use the new field  "Has paid" as  a slicer)

2.Create  a measure as below   and  apply it to the visual filter pane:

 

visual control = IF([Measure Has paid] in DISTINCT('Seperate table'[Value]),1,BLANK())

 

 

The result will show as below:

34.png

Sample pbix attached

 

View solution in original post

10 REPLIES 10
Tahreem24
Super User
Super User

@Anonymous ,

Can you please share the DAX for your measure so we can try to convert it into Column.

 

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
Anonymous
Not applicable

Hi @Tahreem24 

Thanks for your reply

I will share it as long as getting back to the office.

 

 

Hi  , @Anonymous

Measure  cannot be used in  slicer.It is recommended that you convert the measure into a calculated column and use it as a filter if possible.

 

In addition ,here  is another workaround .
1.Create a seperate table ( use the new field  "Has paid" as  a slicer)

2.Create  a measure as below   and  apply it to the visual filter pane:

 

visual control = IF([Measure Has paid] in DISTINCT('Seperate table'[Value]),1,BLANK())

 

 

The result will show as below:

34.png

Sample pbix attached

 

Anonymous
Not applicable

Thank you @v-easonf-msft . Worked perfeclty. 🙂

Anonymous
Not applicable

Hello @Tahreem24 

 

See the DAX below

 

Has Paid? =
IF (
[TotalActivePayersCount] = BLANK (),
BLANK(),
DISTINCTCOUNT ( Payments[ID] )
)

@Anonymous 

Try copying the same in Column and use in the slicer.

 

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
Anonymous
Not applicable

Hi @Anonymous ,

 

You can try to put the measure into the filter pane on the right side.

 

Then you can filter the measure.

 

Aiolos Zhao

Anonymous
Not applicable

Thanks for your suggestion. @Anonymous 

Actually, I would like to create the slicer to give the user the option to filter the data. This is why I have asked about it

Anonymous
Not applicable

Hi @Anonymous 

 

From a user point of view, it will be more user friendly to have a slicer on top of the table which allows the user to filter.

 

Thanks for your suggestion, anyways 

Anonymous
Not applicable

can you change the measure to a calculated column?

 

by the way, the user can also use the filter pane to filter the measure in the front-end.

 

Aiolos Zhao

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.