Forum Discussion

Morgana_2022's avatar
Morgana_2022
Helper I
4 years ago
Solved

Counting values

How do I count some values within a field? Ex. I have the "Fruit" field, made up of the values: Banana Banana Strawberry Kiwi I have to get: Banana = 2 Strawberry = 1 Kiwi = 1 My fo...
  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi Morgana_2022 

    You can through ALLEXCEPT() to count values in groups .

     

    Measure = calculate(COUNT('Table'[Fruit]),ALLEXCEPT('Table','Table'[Fruit]))

     

    The result is as shown :

    Best Regards,
    Community Support Team _ Ailsa Tao
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.