I try to deploy a .dacpac package programmatically using this code:
var dacServices = new DacServices(myConnectionString);
using (var bacPacPackage = DacPackage.Load(dacPacFilename))
{
var options = new PublishOptions();
dacServices.Publish(bacPacPackage, dbName, options);
}
It throws an error:
Microsoft.SqlServer.Dac.DacServicesException: An error occurred during deployment plan generation. Deployment cannot continue. Error 72002: The extension type Microsoft.SqlServer.Dac.Deployment.Internal.InternalDeploymentPlanExecutor could not be instantiated. Error 72002: The extension type Microsoft.SqlServer.Dac.Deployment.Internal.InternalDeploymentPlanModifier could not be instantiated. ---> Microsoft.Data.Tools.Schema.Sql.Deployment.DeploymentFailedException: An error occurred while loading deployment contributors. bei Microsoft.Data.Tools.Schema.Sql.Deployment.SqlDeployment.LoadDeploymentComponents() bei Microsoft.Data.Tools.Schema.Sql.Deployment.SqlDeployment.InitializePlanGeneratator() bei Microsoft.Data.Tools.Schema.Sql.Deployment.SqlDeployment.CreateController(Action`1 msgHandler) bei Microsoft.SqlServer.Dac.DacServices.CreateController(SqlDeployment deploymentEngine, ErrorManager errorManager) --- Ende der internen Ausnahmestapelüberwachung ---
Has anybody any suggestions whats wrong here?