Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more
I have a matrix to show KPI performance with multiple KPI's (field name = job_kpi) and also whether they have passed or failed each month (this is field name = kpi_check).
What I am trying to do is to get the percentage values to display the correct values each month for the pass and fail fields.
So for KPI 1 for April 2021 it would do a calculation for fail of (100/103)*3 but for pass it would do (100/103)*100.
I'm new to power bi / dax so not sure if this is possible - and if so how would I code it so that the figure only looks at the KPI in question, and then does the calculation based on that month only?
Solved! Go to Solution.
Hi @Rob_Morris ,
According to your description, I create a sample.
Here's my solution.
Create a measure.
% =
VAR _Parent =
IF (
ISFILTERED ( 'Table'[KPI Status] ),
CALCULATE ( COUNT ( 'Table'[KPI Status] ), ALL ( 'Table'[KPI Status] ) ),
CALCULATE ( COUNT ( 'Table'[KPI Status] ), ALL ( 'Table'[Job_kpi] ) )
)
RETURN
DIVIDE ( COUNT ( 'Table'[KPI Status] ), _Parent )
Get the correct result.
I attach my sample below for reference.
Best Regards,
Community Support Team _ kalyj
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Rob_Morris ,
According to your description, I create a sample.
Here's my solution.
Create a measure.
% =
VAR _Parent =
IF (
ISFILTERED ( 'Table'[KPI Status] ),
CALCULATE ( COUNT ( 'Table'[KPI Status] ), ALL ( 'Table'[KPI Status] ) ),
CALCULATE ( COUNT ( 'Table'[KPI Status] ), ALL ( 'Table'[Job_kpi] ) )
)
RETURN
DIVIDE ( COUNT ( 'Table'[KPI Status] ), _Parent )
Get the correct result.
I attach my sample below for reference.
Best Regards,
Community Support Team _ kalyj
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Brilliant! Thanks for this it's sorted the issue perfectly.
Instead of showing as percentage of column total, show as percentage of parent total.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.