Change total in pivot table

Copper Contributor

Hi,

 

In my pivot table I have two koloms, 1 has the field option "MAX" and the other "SUM".

In the row total I want to have my results both as "SUM".

Is this possible........

Attached a small example.

 

Thanks in advanced.

2 Replies

@Dirk 

Unfortunately, that is not possible. The subtotals and grand totals in a pivot table always use the same aggregate function as the value field they belong too.

You'd have to place a formula outside the pivot table (but that might be a problem if the pivot table expands).

@Dirk 

Creating PivotTable add data to data model and create measure

Max Amount:=IF(HASONEVALUE(Range[Name]),
      MAX(Range[Amount boxes]),
      SUM([Amount boxes]))

The logic is if one name is filtered (i.e. row) we calculate max, if more than one (i.e. grand total) we sum all.

image.png