'Total Sum of each value column on sap.ui.table

I need to show the total sum of each column that have values on it. But I only can use the sap.ui.table for this.

I look for so much in internet but only found old results with deprecated functions.

Someone can help me, please?

The example that I need to reproduce: image: total sum example



Solution 1:[1]

In case you are using Fiori Elements (e.g. Analytical List Page), you can use:

@DefaultAggregation: #SUM 

on the amount field exposed through the consumption CDS View.

It should automatically show the total sum of the column in the footer of the table.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1