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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
TheCreepster1
Helper II
Helper II

Distinct Count based on percentage measure

Hi All,

 

Not sure if what I'm trying to achieve is possible but I have some information at Site/SKU level where I am performing some aggregate calculations that I then want to perform a distinct count on.

 

Below is some example data:

 

Example Data.PNG

 

The aggregate calculation looks to see if the site should have this SKU in stock, and places a 1/0 flag based on the result. It then calculates to see what % of SKUs are available:

 

Store Roll Up.PNG

 

Now those two bits I can do without problem, and they successfully change with any selected filters, but I'm trying to get to a point where I can see how many Sites fit within a percentage band to give a table like the below:

 

Band.PNG

 

I'm very new to DAX and Power BI so don't know if this is something that can be done? Any hints or pointers will be much appreciated.

 

 

1 ACCEPTED SOLUTION
jthomson
Solution Sage
Solution Sage

Some sort of nested IF would probably work for this if you've only got a small number of options to work with - something like:

 

PercentageGroup = if([currentpercentagemeasure]<0.6,"50-60%",if([currentpercentagemeasure]<0.7,"60-70%"

 

and so on

View solution in original post

1 REPLY 1
jthomson
Solution Sage
Solution Sage

Some sort of nested IF would probably work for this if you've only got a small number of options to work with - something like:

 

PercentageGroup = if([currentpercentagemeasure]<0.6,"50-60%",if([currentpercentagemeasure]<0.7,"60-70%"

 

and so on

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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