Skip to main content

I have data coming from shopify with Line Items being saved into a Google Sheet.  When an order is updated, new data comes in via a zap.

I have to ensure all old line items (that aren’t in the order anymore) are deleted, update any changes to line items and add any new line items.

I decided the best way was to update the existing rows to mark items as updated, and then just add all the new items again.

However I have to look through the google sheets once, and then once that has finished, the Shopify items once.  How do I do this without running a loop inside a loop?

 

 

Hi @Mantzikert 

If you are using the Looping action, there is a data point returned that indicates if it was the last iterated item, that can be used in a following Filter step as described below.

 

Help article: https://zapier.com/help/doc/loop-your-zap-actions

 

How do I stop a loop from running in subsequent action steps?

All actions after the looping step will run. If you don’t want an action step to loop:

  • After the last step you want to loop, add a filter step.
  • Set the filter to only continue if the value loop_iteration_is_last matches the (Boolean) Is True condition.

The filter will run in every loop but will only pass in the last loop. Any actions step after the filter will run once in the last loop and use only 1 task.


Thanks for that.  Obvious now that you point it out.


Hi @Troy Tessalone 

I’ve finally tried to turn on the zap and got the following error.

“Cannot unpause Zap with more than one Looping by Zapier step.”

Have I missed something else that is obvious?

Thanks

Derek