Forum Discussion
sum of max values
- Anonymous10 years ago
Alternative Sum of Max = SUMX(
SUMMARIZE(TableName, TableName[City], "Max Sales", MAX(TableName[Sales])),[Max Sales])
My first formula works on a test table I already had, but it doesn't seem to work right when I typed in your sample table. I can't figure out why that's the case because they both follow a similar pattern, but anyway this second formula works for both.
efanta what should happen if the same max value shows up more than once? Like
City Sales
Buenos Aires 1.000
Buenos Aires 1.000
Mendoza 2.000
Mendoza 2.000
Mendoza 500
Córdoba 3.000
Should the total still be 6000 or would it now be 8000?
- efanta10 years agoFrequent Visitor
Anonymous should consider only once the max value.
- Anonymous10 years agoNot applicable
Sum of Max = SUMX( VALUES(TableName[City]), MAX(TableName[Sales]))
- Anonymous10 years agoNot applicable
Alternative Sum of Max = SUMX(
SUMMARIZE(TableName, TableName[City], "Max Sales", MAX(TableName[Sales])),[Max Sales])
My first formula works on a test table I already had, but it doesn't seem to work right when I typed in your sample table. I can't figure out why that's the case because they both follow a similar pattern, but anyway this second formula works for both.