
Using the Bulk Insert Task with Transactions
If a batch size is not set, the complete bulk copy operation is treated as one transaction. A batch size of 0 indicates that the data is inserted in one batch. If a batch size is set, each batch represents a transaction that is committed when the batch finishes running. For more information, see Implicit Transactions.
The behavior of the Bulk Insert task, as it relates to transactions, depends on whether the task joins the package transaction. If the Bulk Insert task does not join the package transaction, each error-free batch is committed as a unit before the next batch is tried. If the Bulk Insert task joins the package transaction, error-free batches remain in the transaction at the conclusion of the task. These batches are subject to the commit or rollback operation of the package.
A failure in the Bulk Insert task does not automatically roll back successfully loaded batches; similarly, if the task succeeds, batches are not automatically committed. Commit and rollback operations occur only in response to package and workflow property settings.