Hi @Anonymous ,
I think Fail
activity might be able to help you here. :)
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I am trying to pull multiple tables from a Azure SQL Database . When data is loaded to its destination I am calling an SP that will update the status of a table to Success. Using ForEach activity multiple tables are puling. But, While pulling one table if any activity in ForEach fails than after executing fail path the ForEach loop should exit.
As shown in the attached image if copy activity fails than after executing its Fail path which includes activities such as SetPipelineObjectStatus, AuditPipeline and SetPipelineObjectStatusToDefault, ForEach loop should stop means new Iteration should not be started and Pipeline should be failed.
Hey,
@Nasreen Akter , based on my understanding the Fail activity would fail for that iteration but the FOR each activity would take it to the net iteration.
@Anonymous : for you to stop the iterations and pipeline if anything fails within the iteration, you would need to use web activity to disable the ADF pipeline execution via REST API.
Below link is somewhat helpful w.r.t disabling the trigger, you can follow the similar approach to disable the execution:
https://learn.microsoft.com/en-us/answers/questions/160681/how-to-automatically-stop-trigger-in-azure-data-fa.html
Note: This is crude way to exit the loop as it would ensure that your pipeline execution is terminated and no other activities post that loop would be executed even if you wanted it to execute