Ejemplo n.º 1
0
 static void Cleanup()
 {
     using (var context = new EFRecipesEntities())
     {
         context.ExecuteStoreCommand("delete from chapter3.book");
         context.ExecuteStoreCommand("delete from chapter3.category");
     }
 }
Ejemplo n.º 2
0
 static void Cleanup()
 {
     using (var context = new EFRecipesEntities())
     {
         context.ExecuteStoreCommand("delete from chapter7.task");
         context.ExecuteStoreCommand("delete from chapter7.employee");
     }
 }
Ejemplo n.º 3
0
 static void Cleanup()
 {
     using (var context = new EFRecipesEntities())
     {
         context.ExecuteStoreCommand("delete from chapter15.friend");
         context.ExecuteStoreCommand("delete from chapter15.residence");
         context.ExecuteStoreCommand("delete from chapter15.relative");
     }
 }
Ejemplo n.º 4
0
 static void Cleanup()
 {
     using (var context = new EFRecipesEntities())
     {
         context.ExecuteStoreCommand("delete from chapter2.retail");
         context.ExecuteStoreCommand("delete from chapter2.eCommerce");
         context.ExecuteStoreCommand("delete from chapter2.business");
     }
 }
Ejemplo n.º 5
0
 static void Cleanup()
 {
     using (var context = new EFRecipesEntities())
     {
         context.ExecuteStoreCommand("delete from chapter5.contractor");
         context.ExecuteStoreCommand("delete from chapter5.project");
         context.ExecuteStoreCommand("delete from chapter5.manager");
     }
 }
Ejemplo n.º 6
0
 static void Cleanup()
 {
     using (var context = new EFRecipesEntities())
     {
         context.ExecuteStoreCommand("delete from chapter11.[order]");
         // we're re-using customer, so we need to delete from invoice as well!
         context.ExecuteStoreCommand("delete from chapter11.invoice");
         context.ExecuteStoreCommand("delete from chapter11.customer");
     }
 }
        public void InsertTestRecord()
        {
            using (var context = new EFRecipesEntities())
            {
                // delete previous test data
                context.ExecuteStoreCommand("delete from chapter9.client");

                // insert new test data
                context.ExecuteStoreCommand(@"insert into chapter9.client(Name, Email) values ('Jerry Jones','*****@*****.**')");
            }
        }
Ejemplo n.º 8
0
 static void Cleanup()
 {
     using (var context = new EFRecipesEntities())
     {
         context.ExecuteStoreCommand("delete from chapter10.athlete");
     }
 }