Forum Discussion
vanessafvg
8 years agoCommunity Champion
Incorrect Total showing
why would the total still count everything?
measure = CALCULATE(COUNTROWS(Table2), FILTER(Table2, COUNTROWS(Table2) > 1) )
how does one adjust the grand total to reflect the correct amount?
Hi vanessafvg,
Based on my test, the formula below should work in your scenario. :smileyhappy:
Measure 2 = SUMX ( SUMMARIZE ( Table2, Table2[Category], "counts", COUNTA ( Table2[Category] ) ), IF ( [counts] > 1, [counts] ) )Regards
3 Replies
- BeckhamAdvocate II
Check out this blog post by PowerPivotPro:
https://powerpivotpro.com/2012/03/subtotals-and-grand-totals-that-add-up-correctly/
- v-ljerr-msftMicrosoft Employee
Hi vanessafvg,
Based on my test, the formula below should work in your scenario. :smileyhappy:
Measure 2 = SUMX ( SUMMARIZE ( Table2, Table2[Category], "counts", COUNTA ( Table2[Category] ) ), IF ( [counts] > 1, [counts] ) )Regards
- Ashish_MathurSuper User
Hi,
Try this
=SUMX(FILTER(SUMMARIZE(Table2,Table2[Category],"counts",COUNTA (Table2[Category])),[COUNTS]>1).[COUNTS])