Using GrandTotal in Pivot Calculation

Hello,

I am using the Syncfusion Pivot Grid in a WPF application and need to reference the Grand Total (the sum of all values in a row for a specific column) inside a PivotComputationInfo formula.

For example, if I have a pivot grid with Sales Amount as a measure, I would like to create a calculated field that divides each individual value by the grand total of that row to get the percentage contribution of each value in that row.


Is there a way to access the Grand Total in a formula? If not, is there an alternative approach to achieve this?

E.g.

"<syncfusion1:PivotComputationInfo CalculationName="Total" FieldName = "Percentuale Recuperi"

                                         FieldHeader="Percentuale Recuperi" Format = "P" CalculationType="Formula" Formula="[GrandTotalAffidato] / [Affidato]"

                                         SummaryType="DecimalTotalSum" AllowRunTimeGroupByField="False"/>"


1 Reply

RM Rabina Murugan Syncfusion Team February 17, 2025 01:42 PM UTC

Hi Francesco Lolli,

We have investigated the reported scenario. The Grand total cannot be access in a formula of a computation column. Kindly let us know if you need any further assistance.
Regards,
Rabina

Loader.
Up arrow icon