EntityFramework.BulkInsert
EntityFramework.BulkInsert copied to clipboard
How To Enable Trigger when using Bulk insert
using this extension method , will ignore trigger over table that using bulk insert over it
, how to enable trigger to be work with bulk insert
thanks
Try the .BulkInsert(entities, BulkCopyOptions.FireTriggers) you may have to also combine with other flags attributes as well depending on what conditions you'll need: https://github.com/ghost1face/EntityFramework.BulkInsert/blob/master/src/EntityFramework.BulkInsert/BulkCopyOptions.cs#L6
This is a direct mirror of the settings on the SqlBulkCopyOptions class from System.Data.SqlClient: https://learn.microsoft.com/en-us/dotnet/api/system.data.sqlclient.sqlbulkcopyoptions?view=dotnet-plat-ext-8.0