cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Jkaelin Member
Member

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

Accepted Solutions
Super User
Super User

Re: CountX by Category

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!  

2 REPLIES 2
Super User
Super User

Re: CountX by Category

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!  

Jkaelin Member
Member

Re: CountX by Category

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