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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
vcb_001
Frequent Visitor

Creation of a measure regarding count of percentages in a table.

Hi,

 

I'm using a table visual in my dashboard as it is represented in the below, but it is not a data or table that are currently available. I'm just using two columns from a table and 1 measure which has been done by another formula based on a different table's data.

 

The table looks like this:

Application IDApplication NameHealth Score
11220XYZ App100.00%
10200ABC App36%
20031ZRT App100.00%
23911KLM App100.00%
33329OPR App40.00%

 

What I would like to do is quite straigthforward but, it didn't work with the combination of CALCULATE and FILTER formulas. I need to create a measure which counts number of 100.00% Applications to see how many 'fully' healthy applications are there in the table instead of only showing them in the Power BI table.

 

Additionally, another measure is also needed to calculate unhealthy ones which are basically 'not' %100.

1 ACCEPTED SOLUTION
ERD
Community Champion
Community Champion

@vcb_001 , try this measure:

healthy amt =
VAR t = ADDCOLUMNS ( VALUES ( 'Table'[Application ID] ), "score", [Health Score] )
RETURN
    COUNTROWS ( FILTER ( t, [score] = 1 ) )

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

Check out my latest demo report in the data story gallery.

Stand with Ukraine!


Here are official ways you can support Ukraine financially (accounts with multiple currencies):
1) Support the Armed Forces of Ukraine: https://bank.gov.ua/ua/about/support-the-armed-forces
2) Come Back Alive foundation: https://www.comebackalive.in.ua/

Thank you!

View solution in original post

4 REPLIES 4
ERD
Community Champion
Community Champion

@vcb_001 , try this measure:

healthy amt =
VAR t = ADDCOLUMNS ( VALUES ( 'Table'[Application ID] ), "score", [Health Score] )
RETURN
    COUNTROWS ( FILTER ( t, [score] = 1 ) )

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

Check out my latest demo report in the data story gallery.

Stand with Ukraine!


Here are official ways you can support Ukraine financially (accounts with multiple currencies):
1) Support the Armed Forces of Ukraine: https://bank.gov.ua/ua/about/support-the-armed-forces
2) Come Back Alive foundation: https://www.comebackalive.in.ua/

Thank you!

vcb_001
Frequent Visitor

Thank you for your valuable answer!

Could you please also help me to adapt this measure for the ones which are below 100% and above 75% as a new category (new measure)?

ERD
Community Champion
Community Champion

 

lower amt =
VAR t = ADDCOLUMNS ( VALUES ( 'Table'[Application ID] ), "score", [Health Score] )
RETURN
    COUNTROWS ( FILTER ( t, [score] < 0.75 ) )
mid amt =
VAR t = ADDCOLUMNS ( VALUES ( 'Table'[Application ID] ), "score", [Health Score] )
RETURN
    COUNTROWS ( FILTER ( t, [score] < 1 && [score] > 0.75 ) )

 

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

Check out my latest demo report in the data story gallery.

Stand with Ukraine!


Here are official ways you can support Ukraine financially (accounts with multiple currencies):
1) Support the Armed Forces of Ukraine: https://bank.gov.ua/ua/about/support-the-armed-forces
2) Come Back Alive foundation: https://www.comebackalive.in.ua/

Thank you!

vcb_001
Frequent Visitor

Hello again,

 

I greatly appreciate what you've done so far for this measure and it supported a lot to improve the structure of my dashboard. I thought for a new improvement based on the same logic you've shared in the above which is basically a filter that includes 3 categories for example, 'Fully Healthy', 'Mid Healthy' and 'Unhealthy'. How could I do that, Can you please help me either to create this custom column as well as the relevant filter based on that one?

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!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

December 2024

A Year in Review - December 2024

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