How to transaction rollback in ssis?

爱⌒轻易说出口 提交于 2020-01-09 05:20:08

问题


I have data import to Production server. In my package cleanse raw tables before data load. If any case package failed . How to rollback raw tables data in SSIS ?


回答1:


By using Sequence Containers (Sequence, For Loop, ForEach Loop) in SSIS, you can make use of a property called TransactionOption. This allows you to specify the transactional behaviour of the tasks in your package, and the package itself to rollback if any tasks fail.

For example, if you stick your tasks in a Sequence Container and set TransactionOption=Required, and configure all Tasks within the Container to TransactionOption=Supported, they will all join the transaction started in the Sequence Container, and if any fail, the transaction will be rolled back.

You can read an explanation of the TransactionOption property here and/or follow the walkthrough here to see how to implement this.

EDIT: Another good walkthrough (with screenshots) here



来源:https://stackoverflow.com/questions/13626755/how-to-transaction-rollback-in-ssis

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