I have a scenario where I will be showing only two rows (say A, B). By default, NReco always shows the Grand Total(A+B) as the last row. I would like to have Difference (A-B) instead of Grand Total.
How I can achieve this?
I have a scenario where I will be showing only two rows (say A, B). By default, NReco always shows the Grand Total(A+B) as the last row. I would like to have Difference (A-B) instead of Grand Total.
How I can achieve this?
Grand total calculation in the pivot table relies on the aggregate function, so if you use, say, SumAggregatorFactory
it total for A and B shows A+B. You can implement your own aggregate function for your own logic to achieve the desired grand total value. It is unclear what exactly you want to achieve as A-B definitely depends on the rows order, but aggregate function should NOT rely on the order - so maybe your table is not a pivot table at all?..