Created
May 8, 2014 11:49
-
-
Save danmusk/23d0c96aec7ec1f037ca to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BulkInsert (transaction) | |
var insert = @" | |
INSERT INTO table (value1, value2) | |
VALUES (@value1, @value1); | |
"; | |
using (var scope = new System.Transactions.TransactionScope()) | |
{ | |
_dbConnection.Open(); | |
_dbConnection.Execute(insert, listOfStuff); | |
scope.Complete(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment