问题描述
在 SSIS 包中,我有一个 For Loop Container 任务,其中 EvalExpression 设置为 true(以便它永远运行).如果 For 循环容器内的任何任务失败,那么包必须失败——除了执行包任务(调用子包).如果失败,那么父包应该转移到下一个任务.
In an SSIS package, I have a For Loop Container task with the EvalExpression set to true (so that it runs forever). If any tasks inside the For Loop Container fail, then the package must fail -- except for the Execute Package task (that calls a child package). If that fails, then the parent package should move onto the next task.
我尝试将执行包任务的 MaximumErrorCount 设置为 0,但这没有帮助.我尝试将 For Loop Container 任务的 MaximumErrorCount 设置为 0,但这会忽略 For Loop Container 任务中所有任务的错误.
I tried setting the MaximumErrorCount of the Execute Package task to 0, but that didn't help.I tried setting the MaximumErrorCount of the For Loop Container task to 0, but that ignores the errors of all the tasks within the For Loop Container task.
知道如何在 For 循环容器内仅忽略执行包任务上的错误.
Any idea how I can ignore errors on only the Execute Package task -- within a For Loop Container.
推荐答案
答案是对所有应该导致包停止的任务使用 FailPackageOnFailure 属性,并将 For Loop Container 任务的 MaximumErrorCount 设置为 0.
The answer is to use the FailPackageOnFailure property for all the tasks that should cause the package to stop and set the MaximumErrorCount of the For Loop Container task to 0.
这篇关于忽略 SSIS 中执行包任务的错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!