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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
DennisSchlein
Helper III
Helper III

How to show % of total - on subgroups

Hi 

I'm fairly new to PBI. I have created a table with a status code - that represents the values from the bottom table:

Status Code	Status Text
1	1
2	2
3	3
4	4
5	5
6	6
7	7
8	8
9	9
10	10
1000	10+
1001	Invalid Data
1002	No CMR Scan
1003	Not Shipped
1004	Not Delivered
1005	Missing SLA Leadtime
1006	Delayed
1007	On Time


In my raport I want to show 2 group - Active shipments (Status Code: 1000, 10004, 1006 and 1007. That part is easy because I can just apply a filter to my visual.

Then I want to show data with issues- Status: 1001, 1002, 1003 & 1005. But as a % of the total. But if I apply a filter on my visual I get it as a % of the filtered total.

How to come around that?


Kind regards,



image.png

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @DennisSchlein ,

Below is my table:

vxiandatmsft_0-1708566784128.png

The following DAX might work for you:

 

Shipments with Issues = COUNTROWS(FILTER('Table', 'Table'[Status Code] IN {1001, 1002, 1003, 1005}))


Measure2 = CALCULATE(COUNTROWS('Table'),ALL('Table'))



total % = DIVIDE([Shipments with Issues],[Measure2],0) 

 

The final output is shown in the following figure:

vxiandatmsft_1-1708566846751.png

Best Regards,

Xianda Tang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
DennisSchlein
Helper III
Helper III

Hi @Anonymous  - Sorry for the late reply.
This is exactly what I was looking for. Thank you very much 🙂 

Anonymous
Not applicable

Hi @DennisSchlein ,

Below is my table:

vxiandatmsft_0-1708566784128.png

The following DAX might work for you:

 

Shipments with Issues = COUNTROWS(FILTER('Table', 'Table'[Status Code] IN {1001, 1002, 1003, 1005}))


Measure2 = CALCULATE(COUNTROWS('Table'),ALL('Table'))



total % = DIVIDE([Shipments with Issues],[Measure2],0) 

 

The final output is shown in the following figure:

vxiandatmsft_1-1708566846751.png

Best Regards,

Xianda Tang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.