Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid configuration combination for RemoveSqlCmdStatements #11

Closed
Herdo opened this issue Jul 9, 2019 · 0 comments
Closed

Invalid configuration combination for RemoveSqlCmdStatements #11

Herdo opened this issue Jul 9, 2019 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@Herdo
Copy link
Owner

Herdo commented Jul 9, 2019

Affected version: 1.2.0

Description: RemoveSqlCmdStatements = true will create a wrong script, when certain publish profile settings are set to true.

Additional information:

  • The setting CreateNewDatabase of the publish profile will add a USE [master] and more to the created script, after which the current database will be dropped, if it exists, and a new one is created. Afterwards, a USE [$(DatabaseName)] will be executed, which will switch the script back to the correct database.
  • The setting BackupDatabaseBeforeChanges of the publish profile will add a IF (DB_ID(N'$(DatabaseName)') IS NOT NULL) and more to the created script, after which the current database will be backed up. Afterwards, a USE [$(DatabaseName)] will be executed, which will switch the script back to the correct database.
  • The setting ScriptDatabaseOptions of the publish profile will add multiple database statements that use the $(DatabaseName) variable.
  • The setting ScriptDeployStateChecks of the publish profile will add multiple database statements that use the $(DatabaseName) variable.

The points above, in combination with the extensions configuration RemoveSqlCmdStatements will cause in a script that will execute not as intended, or won't run at all, depending on the executing application.

@Herdo Herdo added the bug Something isn't working label Jul 9, 2019
@Herdo Herdo added this to the v1.3.0 - Enterprise Features milestone Jul 9, 2019
@Herdo Herdo self-assigned this Jul 9, 2019
@Herdo Herdo changed the title Invalid configuration combination for CreateNewDatabase and RemoveSqlCmdStatements Invalid configuration combination for RemoveSqlCmdStatements Jul 9, 2019
@Herdo Herdo closed this as completed Jul 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant