Forum Discussion
Anonymous
7 years agoNot applicable
DAX Calculation for Aggregated values inside single table
Hi all, I need a little DAX help! I have the following table structure: Customer NID AgentCount AAA 15897457 1 AAA 67845217 4 AAA 58579248 3 AAA 82465752 4 BBB 5...
- 7 years ago
Hi Anonymous,
Based on my test, you could refer below steps to get the Calc1:
Create a calculated column:
Column = CALCULATE(COUNT(Table1[Customer]),FILTER('Table1','Table1'[Customer]=EARLIER(Table1[Customer])))Create a measure and you could get the correct result:
Calc1 = CALCULATE(COUNT(Table1[Column]),FILTER('Table1',Table1[Column]=1))/DISTINCTCOUNT(Table1[Customer])You could also download the pbix file to have a view.
Regards,
Daniel He
Anonymous
7 years agoNot applicable
Thanks, the 2nd calc works fine.
However im getting error with calc1:
NormalisedDays=TableName
FCRv1 = MeasureName
Im not even using AddMissingItems() in the calculation. Any Ideas?
v-danhe-msft
7 years agoMicrosoft Employee
Hi Anonymous,
Based on my test, you could refer below steps to get the Calc1:
Create a calculated column:
Column = CALCULATE(COUNT(Table1[Customer]),FILTER('Table1','Table1'[Customer]=EARLIER(Table1[Customer])))
Create a measure and you could get the correct result:
Calc1 = CALCULATE(COUNT(Table1[Column]),FILTER('Table1',Table1[Column]=1))/DISTINCTCOUNT(Table1[Customer])
You could also download the pbix file to have a view.
Regards,
Daniel He