Bulk insert using EntityFramework Extended
问题 According to this, bulk insert in Entity can be made using the following code: var customers = GetCustomers(); db.Customers.AddRange(customers); db.SaveChanges(); I used SQL Profiler to verify how many insert queries were executed and I saw there was an insert for each element of the list. Why? 回答1: AddRange Add range doesn't perform a BulkInsert, it simply DetectChanges once after all entities are added to the set. The DetectChange method can be VERY slow. See: Entity Framework -