pjbro1965
Forms Fledgling

sum multiple line items to another list under conditions

=SUMIFS(field6,field2,"11",field3,"10")

Need a workflow that queries list A

Looks in Field 1 to see if it contains the number 11

And

Looks in Field 2 to see if it contains the number 10

If true it gets the number in Field 6 of that Item ID and stores it.

Then after collecting all in list that meet this fact

Adds them up and stores in a col variable

Then takes that number and puts it in List B Field 2 for this fact.

 

Col1.png

 

I have tried the following:

col2.pngCol3.pngCol4.pngCol5.pngCol6.png

Any Ideas what I am doing wrong?

0 Kudos
Reply
1 Reply
SimonMuntz
Nintex Employee
Nintex Employee

Re: sum multiple line items to another list under conditions

Hi,

The issue is the collection operation.
It is using the POP operation which only grabs the last value out of the collection and stores it in your variable. It is not used to total all the values.

You need to run the collection variable through a For Each action that contains a Math Operation that adds each item in the collection to a grand total varaible.
0 Kudos
Reply