Within a flow, I am using the 'List Records' action. I have successfully applied an OData filter that only lists records with the appropriate project value. Is it possible to also apply an aggregate transformation to sum the numeric values of a field in the filtered items.
Yes, it is possible.
Within PowerApps, there is a Sum () function available to sum the special field within a table.
Sum( Table, NumericalFormula )
Sum(Sales, CostPerUnit * UnitsSold)
The label would show total sales by multiplying the values in those columns for each record and then adding the results from all records together:
If you would like to do it within Microsoft Flow, you need to take use of Variable and an Apply to each to sum the numeric field value within a table.
If here you prefer Microsoft Flow, then please try the steps below:
1. After the Get Items action, add two Variables, name them with SumField, another with Total,
2. Add an Apply to each, enter the Value of the Get Items action,
3. within Apply to each, add two Set Variable action,
4. For the first Set Variable action, select SumField, with the value enter the following expression:
Here I take use of the SharePoint Get Items action ID field as an example.
5. with the second Set Variable action, select Total Value, enter the value field with:
6. Outside Apply to each, take use of the compose to check the Total Variable value.