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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
Jkaelin
Resolver I
Resolver I

CountX by Category

Hey everyone,

 

Struggling to correct write this measure.

 

I want to return the distinct count of the categories that have a status of 1, more than once.  

 

Below, the result should be 2.  I want to count each category (A & F) that have a status of 1 that is counted more than once.  Each category will have a status of 1, but I want the unique count of each category that has it listed more than once.  

 

Thoughts?  Any help is greatly appreciated.  Thank you!!

DistinctCount1.PNG

 

 

 

1 ACCEPTED SOLUTION
LivioLanzo
Solution Sage
Solution Sage

Hi @Jkaelin

 

=COUNTROWS(
    FILTER(
        VALUES( Statuses[Category] ),
        CALCULATE( COUNTROWS( Statuses ), Statuses[Status] = 1 ) > 1
    )
)

 


 


Did I answer your question correctly? Mark my answer as a solution!


Proud to be a Datanaut!  

View solution in original post

2 REPLIES 2
LivioLanzo
Solution Sage
Solution Sage

Hi @Jkaelin

 

=COUNTROWS(
    FILTER(
        VALUES( Statuses[Category] ),
        CALCULATE( COUNTROWS( Statuses ), Statuses[Status] = 1 ) > 1
    )
)

 


 


Did I answer your question correctly? Mark my answer as a solution!


Proud to be a Datanaut!  

@LivioLanzoDang that was fast & accurate.  You the man!!  Thank you very much.  

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!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

Feb2025 NL Carousel

Fabric Community Update - February 2025

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