Forum Discussion

kheldar's avatar
kheldar
Iron Contributor
Dec 30, 2021
Solved

DAX with SUM and MAX

Hello,   I've got a Pivot Table constructed like this       How can I get max of summed values of that field?   I've tried this but it fails.   =MAXX(SUMMARIZE(Table31,[Output]))  
  • SergeiBaklan's avatar
    Dec 30, 2021

    kheldar 

    Let take such sample

    You may create measures

    V, sum:=CALCULATE( SUM(Table1[V] ), ALLEXCEPT(Table1, Table1[A], Table1[B] ) )
    
    V, max Sum:=MAXX( ALLEXCEPT(Table1, Table1[A] ), [V, sum] )
    
    Max of Sum:=IF( HASONEVALUE(Table1[B]), [V, sum], [V, max Sum] )

    and use the latest one in PivotTable.

Resources