Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago
Solved

How to count all duplicate and single values

Hi,   I would like to count the number of employee by department, and I use this formula Attrition HC 2 = CALCULATE( COUNTROWS(except(values(Terminate[ID]),VALUES(Zero[Employee ID]))),Reasons_Loo...
  • ValtteriN's avatar
    ValtteriN
    2 years ago

    I see so you want to exclude Zero values. 

    With that in mind try this:

    Measure = CALCULATE(COUNT('Table (2)'[Employee ID]),'Table (2)'[Status]="Voluntary",EXCEPT(VALUES('Table (2)'[Employee ID]),VALUES('Zero'[EID])))


    Test: (no except)

    With: