Install() public method

public Install ( System.Version assemblyVersion ) : void
assemblyVersion System.Version
return void
Exemplo n.º 1
0
        public static void CreateAndInstallDatabase(ConnectionString connectionString, string databaseName, string directory)
        {
            DeleteDatabase(connectionString.Server, databaseName, directory);
            CreateDatabase(connectionString.Server, databaseName, directory);

            SqlInstaller installer = new SqlInstaller(connectionString);
            installer.Install(VersionInfo.FrameworkVersion);
        }
Exemplo n.º 2
0
        protected override void ExecuteCommand(Arguments arguments)
        {
            if (arguments.Contains("recreate-db"))
            {
                DropDatabase(arguments["connect"]);
            }

            if (arguments.Contains("create-db") || arguments.Contains("recreate-db"))
            {
                CreateDatabase(arguments["connect"]);
            }

            SqlInstaller installer = new SqlInstaller(arguments["connect"]);
            installer.Install(VersionInfo.FrameworkVersion);
        }
Exemplo n.º 3
0
 public static void InstallDatabase(string connectionString)
 {
     SqlInstaller installer = new SqlInstaller(connectionString);
     installer.Install(VersionInfo.FrameworkVersion);
 }