Showing results for 
Search instead for 
Did you mean: 
Not applicable

Iterating through multiple collections at the same time

Hello, I'm currently trying to develop a workflow that tracks data sheets and emails someone if they have expired (after 3 years) so they can update them. However, I've currently ran into a problem. What I'm currently trying to do is query the list and get all of the names of the documents as well as all of the data sheets dates but I have no way of iterating through both lists at the same time and then sending and email after each iteration. The reason why I need to iterate through both collections is that I need to first compare to see if it is expired and then if it is I need to email the name of the document to someone. Hopefully I'm clear enough but if I'm not here is a pseudo-code workflow of whats going on

1. querylist -> gets the name of the documents and the creation dates

2. for-each loop -> currently only running through creation date collection (unsure how to go through the name collection as well)

    3. (in the loop) run if -> checks if the document is expired or not

    4. (in the loop) email notification -> emails someone telling the document is expired (I can't get the name of the document)

There may be a simpler way of doing this but I'm very new to nintex so i'm not sure of all the tricks yet.

Labels: (2)
2 Replies
Workflow Hero

Re: Iterating through multiple collections at the same time

Hi, I had exactly the same issue - i created an iteration through the list item ID and then a filtered query list in the loop setting two variables with the list fields I need for further processing.

1. Query List item ID to a collection

2. Loop through the ID's

3. Store the list colums you need into separate variable using query list actions using a filter on ID

4. process the variables as you need

hope this helps...

0 Kudos
Accept as Solution Reply
Workflow Hero

Re: Iterating through multiple collections at the same time

Hi Joshua,

in step 2 of Your pseudo code using 'For each' action and store index in workflow variable.

This index You can use in a 'Collection operation' action in step 4 to access the document name. Use 'get' in 'Collection operation' and specify index as previous stored index.

Kind regards


0 Kudos
Accept as Solution Reply