title: Create database using code first Entity Framework in SQL Server
body: <p>I am using code first EF and new to this framework. I am trying to create a database using <code>Database.SetInitializer</code> but it looks like I need SQL Server Express. But I have to create database in SQL Server 2014. How to do this?</p>
  
  <p>Can anybody explain this with the example from EF-dbcontext book which has following classes.</p>
  
  <pre><code> public class BreakAwayContext : DbContext
   {
      public DbSet&lt;Destination&gt; Destinations { get; set; }
      public DbSet&lt;Lodging&gt; Lodgings { get; set; }
      public DbSet&lt;Trip&gt; Trips { get; set; }
      public DbSet&lt;Person&gt; People { get; set; }
      public DbSet&lt;Reservation&gt; Reservations { get; set; }
      public DbSet&lt;Payment&gt; Payments { get; set; }
      public DbSet&lt;Activity&gt; Activities { get; set; }
  }
  class Program
  {
  
  
  static void Main(string[] args)
   {
    Database.SetInitializer(new InitializeBagaDatabaseWithSeedData());
    try
    {
        using (var context = new BreakAwayContext())
        {
            foreach (var destination in context.Destinations)
                Console.WriteLine(destination.Name);
        }
    }
      catch(Exception ex){
  
        Console.WriteLine(ex.ToString());
      }
    Console.Read();  
  }
  }
  
   public class InitializeBagaDatabaseWithSeedData : DropCreateDatabaseAlways&lt;BreakAwayContext&gt;
    {
      protected override void Seed(BreakAwayContext context)
      {
        context.Destinations.Add(new Destination
        {
          Name = "Hawaii",
          Country = "USA",
          Description = "Sunshine, beaches and fun."
        });
  
        context.Destinations.Add(new Destination
        {
          Name = "Wine Glass Bay",
          Country = "Australia",
          Description = "Picturesque sandy beaches."
        });
  }
  </code></pre>