コード例 #1
0
 public static void DeleteDatabase()
 {
     using (var context = new Dining(ConnectionString))
     {
         if (context.DatabaseExists())
         {
             // delete database if it exist
             context.DeleteDatabase();
         }
     }
 }
コード例 #2
0
 public static void DeleteDatabase()
 {
     using (var context = new Dining(ConnectionString))
     {
         if (context.DatabaseExists())
         {
             // delete database if it exist
             context.DeleteDatabase();
         }
     }
 }
コード例 #3
0
 public static void CreateDatabase()
 {
     using (var context = new Dining(ConnectionString))
     {
         if (!context.DatabaseExists())
         {
             // create database if it does not exist
             context.CreateDatabase();
         }
     }
 }
コード例 #4
0
 public static void CreateDatabase()
 {
     using (var context = new Dining(ConnectionString))
     {
         if (!context.DatabaseExists())
         {
             // create database if it does not exist
             context.CreateDatabase();
         }
     }
 }