Is there a way to cause OnError to fire with no error

送分小仙女□ 提交于 2020-01-05 11:52:40

问题


I want to make the OnError event handler fire with custom values. In other words, I want to raise an error. Is there a way to do that in SSIS?

There is no actual error condition. It would be an error in business logic that I would like to handle with the error handling procedures I've already established.


回答1:


Add a script task and call the Dts.Events.FireError method

  • http://technet.microsoft.com/en-us/library/ms136054.aspx
  • Firing events in script task
  • http://consultingblogs.emc.com/jamiethomson/archive/2005/11/03/SSIS_3A00_-Throwing-errors-from-script-task_2F00_component.aspx


来源:https://stackoverflow.com/questions/19568681/is-there-a-way-to-cause-onerror-to-fire-with-no-error

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!