sqlpackage.exe 发布联合异常
sqlpackage.exe publish conjunction exception
我正在尝试使用 sqlpackage
工具来发布思想 CMD
:
sqlpackage /action:Publish /SourceFile:"Database Services\bin\Release\Database Services.dacpac" /TargetDatabaseName:test /TargetConnectionString:"Data Source=TEST05,123;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Connect Timeout=60;Encrypt=False;TrustServerCertificate=False"
我遇到了这个异常:
** The TargetConnectionString argument cannot be used in conjunction with any other Target database arguments.
我不明白这是什么意思,我之前可以使用 msbuild
:
部署它
msbuild "Database Services\Database Services.sqlproj" /t:deploy /p:Configuration=Release /p:TargetConnectionString="Data Source=TEST05,123;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Connect Timeout=60;Encrypt=False;TrustServerCertificate=False" /p:BlockOnPossibleDataLoss=False /p:TargetDatabase="test"
我找到了一个可能相关的话题:
遵循此 article,我能够使用以下语法发布:
sqlpackage /action:Publish /SourceFile:"Database Services\bin\Release\Database Services.dacpac" /TargetConnectionString:"Data Source=TEST05,123;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Connect Timeout=60;Encrypt=False;TrustServerCertificate=False;Initial catalog=test"
我正在尝试使用 sqlpackage
工具来发布思想 CMD
:
sqlpackage /action:Publish /SourceFile:"Database Services\bin\Release\Database Services.dacpac" /TargetDatabaseName:test /TargetConnectionString:"Data Source=TEST05,123;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Connect Timeout=60;Encrypt=False;TrustServerCertificate=False"
我遇到了这个异常:
** The TargetConnectionString argument cannot be used in conjunction with any other Target database arguments.
我不明白这是什么意思,我之前可以使用 msbuild
:
msbuild "Database Services\Database Services.sqlproj" /t:deploy /p:Configuration=Release /p:TargetConnectionString="Data Source=TEST05,123;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Connect Timeout=60;Encrypt=False;TrustServerCertificate=False" /p:BlockOnPossibleDataLoss=False /p:TargetDatabase="test"
我找到了一个可能相关的话题:
遵循此 article,我能够使用以下语法发布:
sqlpackage /action:Publish /SourceFile:"Database Services\bin\Release\Database Services.dacpac" /TargetConnectionString:"Data Source=TEST05,123;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Connect Timeout=60;Encrypt=False;TrustServerCertificate=False;Initial catalog=test"