Forum Discussion

SAPpowerbi's avatar
SAPpowerbi
Helper II
3 years ago
Solved

duplicate values count based on another column values

Hello Team ,   I want count based on business line  for category 1,Please help me to write a dax column . Please find below tabel for example. I want output based on category 1 and business Line ...
  • v-zhangti's avatar
    3 years ago

    Hi, SAPpowerbi 

     

    You can try the following methods.

    Column =
    CALCULATE (
        COUNT ( 'Table'[Category 1] ),
        FILTER ( 'Table', [Category 1] = EARLIER ( 'Table'[Category 1] ) )
    )
    

    Is this the result you expect?

     

    Best Regards,

    Community Support Team _Charlotte

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