How to make a SSIS transaction in my case?

2019-09-17 12:18发布

问题:

I am using SSIS 2008.

Let a person be defined by PersonID, a number. In my SSIS package, for each person, I first load some info into Table1 (with execute sql task) and then some info into Table2 (with execute sql task). I want this entire process to be considered as a transaction. That is, the transaction is complete only when information for A person is loaded both into Table1 and Table2. If we could not load info into Table2, then info already loaded in Table1 should not be committed.

How do I do this ?

Thanks.

回答1:

Place both of your loads into a sequence container set transaction option to required in the properties tab. Done. Included is an article in case you need additional details.