When the second set of data enters the loop node, the loop does not occur; instead, it goes to the ‘done’ node.
How can I fix this so that whenever data passes through the loop node, it gets written to Google Sheets? For instance, when I set a data set of 5, it loops through all 5 items perfectly. However, when the initial node is called a second time, the loop does not happen.
@salsiy , you don’t need the IF node to check if the looping is complete. It’s totally redundant and unnecessary. If you want to start over with a datastore, use the “done” output of the loop. However, you should ensure that the loop doesn’t become endless unless the datastore node eventually returns nothing, thereby stopping the workflow (generally speaking).
Specifically to your workflow, this is what should do
@ihortom Thanks for the reply , im putting my actual workflow , so you will have more clarity on what im trying to acheive. when data enters the loop block for second time its not processing as expected , maybe im doing the wrong way. Here is my complete workflow
@salsiy , thanks for the fuller picture. As I cannot run your workflow I might be wrong. However, I would not use Loop in this case at all. What you need is a pagination technique for GraphQL node.
For clarity, here’s what I mean. It’s just a visualization of the concept to give you an idea, not a working workflow.
You just need to figure out the changes needed for the nodes in the yellow square. You might need to add IF in there and some other transformation but it should be doable.