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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
Anonymous
Not applicable

Matrix with multiple months and percentages

Hello community,

 

I have a problem and I think it would be not so hard, but I haven't yet experience with this tool.

I have a Matrix with following elements (from the visualizations pane)

  • Rows: Customers
  • Columns: Status (can be OK or KO), Month.
  • Values: Number of IDs (count of those unique identifiers) , % (percentage of those IDs on the total).

If I select one month, I have (say)

statusKO OK TOTAL
monthoctober    
customerN%N% 
AAA2020%8080%100%

 

But If I select more than one month (say two) I need to have that every month sum up at 100% in every subtotal. Instead, I obtain the percentage of grand total and that's not what I want..

 

THere is a Measure I could create to achieve this goal?

 

Thanks in advance!

1 ACCEPTED SOLUTION
V-lianl-msft
Community Support
Community Support

You can try to create a measure like below:

Measure = 
var current_ = DISTINCTCOUNT('Table'[ID])
var total_per_month = CALCULATE(DISTINCTCOUNT('Table'[ID]),ALLEXCEPT('Table','Table'[Month]))
return DIVIDE(current_,total_per_month)

Vlianlmsft_0-1636964604428.png

 

View solution in original post

2 REPLIES 2
V-lianl-msft
Community Support
Community Support

You can try to create a measure like below:

Measure = 
var current_ = DISTINCTCOUNT('Table'[ID])
var total_per_month = CALCULATE(DISTINCTCOUNT('Table'[ID]),ALLEXCEPT('Table','Table'[Month]))
return DIVIDE(current_,total_per_month)

Vlianlmsft_0-1636964604428.png

 

amitchandak
Super User
Super User

@Anonymous , Try a measure like

 

divide(count(Table[unique identifiers]) ,calculate( count(Table[unique identifiers]), removefilters(Table[Status])) )

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! It's time to submit your entry.

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

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.