Last active
November 30, 2016 16:03
-
-
Save zzzprojects/8b009471c625e5bd792d8f92c9591a33 to your computer and use it in GitHub Desktop.
This file contains 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
// DON'T add the key if auto-generated | |
ctx.BulkInsert(customers, operation => operation.ColumnInputExpression = | |
customer => new {customer.Name, customer.Email}); | |
// ALWAYS add the key | |
ctx.BulkUpdate(customers, operation => operation.ColumnInputExpression = | |
customer => new { customer.ID, customer.Name, customer.Email }); | |
// ALWAYS add the key | |
ctx.BulkMerge(customers, operation => operation.ColumnInputExpression = | |
customer => new {customer.ID, customer.Name, customer.Email}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment