Forum Discussion
Corleen
9 years agoRegular Visitor
Count a Measure or Countif
Good day Please assist I've created a measure to count how many times a person id comes forth in the data. # times = CALCULATE(COUNT('TransactionDetails'[SYSTEM_NUM]),'TransactionDetails'...
Amratya
Advocate I
9 years agoHi Corleen,
Usually you can use below in counting reference to a column
CALCULATE (
COUNTROWS ( 'TableName' ),
ALLEXCEPT (
'TableName',
'TableName'[Coulmn_you_want_to_count],
'TableName'[Reference_Coulmn],
)
)
Corleen
9 years agoRegular Visitor
Thank you for your reply.
But it is a measure not a calculated column
For eg.
Trans Once = count([# times] = 1) I want the answer for this, how to do this?
Trans Twice = count([# times] = 2)
where
[# times] = CALCULATE(COUNT('TransDetail'[SYSTEM_NUM]),'TransDetail'[EARN_DEDUCT_IND]=1)
Thanks