Attribute calculation for all objects in a grid

1
I would like to fill the stored attribute 'InvoiceAmountOut', which is part of the Customer entity, with the total overdue invoice amount. Hence, I created below microflow, which correctly calculates the 'InvoiceAmountOut' for the first customer of the list. However, my goal is to calculate this amount for all customers in the list. It makes sense that the microflow currently does not give the correct outcome, as the invoice retrieve activity is done over association and therefore only retrieves invoices of the first customer. Unfortunately, I cannot find a way to get all invoices and correctly assign the overdue amounts to the customers. Could you advise me how to achieve this?    
asked
3 answers
1

The mistake you make is that you should commit the value IN the iteration of the customer. You now change it after the iteration. My assumption is that the list you are getting is the list with all the customers.

Regards,

Ronald

[EDIT]

 

 

Hope this helps.

 

answered
0

I think you would have to add the activity retrieve List of Invoice by Customer association inside your Customer Iteration Loop. This will retrieve the Invoices of all the customers. Keeping it outside retrieves the Invoice of only One Customer object that's being passed as input parameter. Make sense?

answered
0

Thank you so much Ronald. It works now. Such a powerful tool!

answered