public void Restore(string databaseName) { string bakPath = $"{localPath}\\{temporaryDatabase}.bak"; string mdfPath = $"{localPath}\\{databaseName}.mdf"; string ldfPath = $"{localPath}\\{databaseName}.ldf"; SqlOperations.Restore(options.Destination.Server, bakPath, mdfPath, ldfPath, databaseName, temporaryDatabase); }
public void Backup() { string path = $"{localPath}\\{temporaryDatabase}.bak"; SqlOperations.Backup(path, options.Destination.Server, options.Destination.Database); }
public void Rename() { SqlOperations.DropDatabase(options.Destination.Server, options.Destination.Database); SqlOperations.RenameDatabase(options.Destination.Server, temporaryDatabase, options.Destination.Database); }