Skip to main content

i have created a zap to delete all the records in a table and had to use a loop to do so. i was not able create a nested loop to then add the new records. i created a sub zap and then kept running into an error because i cannot return to a zap from a loop. if i put the delete a record and an add a record in the same loop and they could be different amounts of each will it work? maybe if add a field and turn it on or something. if not what is the best way to do this. Overall goal is: Have a table in ZApier that all records need to be deleted and new records added when we trigger a Zap. Thanks in advance.

To pull off a nested loop, you have to do two Zaps. Create one with a webhook trigger that does whatever action you were trying to do in the sub-Zap, then from within the parent Zap, POST to that webhook within the loop. 


Hey ​@Jazzy3,

Nested Loops are not supported in Sub Zaps if you see here- https://help.zapier.com/hc/en-us/articles/32283713627533-Understanding-Sub-Zaps
 



Though nested loops are not natively supported there is workaround through using two Zaps and Webhooks or a Code by Zapier action. Here are helpful articles about Webhooks in Zapier and Code by Zapier-

https://help.zapier.com/hc/en-us/articles/8496083355661-How-to-get-started-with-Webhooks-by-Zapier

https://zapier.com/blog/code-by-zapier-guide/

Hope it helps!