using System.Data.Entity;
using System.Collections.Generic;
public static void Main()
List<Customer> list = new List<Customer>() { new Customer() { Name ="Customer_A", Description = "Description" , IsActive = false },
new Customer() { Name ="Customer_B", Description = "Description", IsActive = true },
new Customer() { Name ="Customer_C", Description = "Description" , IsActive = true }};
using (var context = new EntityContext())
context.BulkInsert(list, options => options.ColumnInputExpression = c => new { c.Name, c.IsActive });
FiddleHelper.WriteTable(context.Customers.ToList());
public class EntityContext : DbContext
public EntityContext() : base(FiddleHelper.GetConnectionStringSqlServer())
public DbSet<Customer> Customers { get; set; }
public int CustomerID { get; set; }
public string Name { get; set; }
public string Description { get; set; }
public Boolean IsActive { get; set; }