{"action":"created","issue":{"url":"https://api.github.com/repos/Microsoft/vsts-tasks/issues/2350","repository_url":"https://api.github.com/repos/Microsoft/vsts-tasks","labels_url":"https://api.github.com/repos/Microsoft/vsts-tasks/issues/2350/labels{/name}","comments_url":"https://api.github.com/repos/Microsoft/vsts-tasks/issues/2350/comments","events_url":"https://api.github.com/repos/Microsoft/vsts-tasks/issues/2350/events","html_url":"https://github.com/Microsoft/vsts-tasks/issues/2350","id":173611329,"number":2350,"title":"Deploy Azure SQL DACPAC error when set /p:BackupDatabaseBeforeChanges=True","user":{"login":"ramedey","id":6451985,"avatar_url":"https://avatars.githubusercontent.com/u/6451985?v=3","gravatar_id":"","url":"https://api.github.com/users/ramedey","html_url":"https://github.com/ramedey","followers_url":"https://api.github.com/users/ramedey/followers","following_url":"https://api.github.com/users/ramedey/following{/other_user}","gists_url":"https://api.github.com/users/ramedey/gists{/gist_id}","starred_url":"https://api.github.com/users/ramedey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ramedey/subscriptions","organizations_url":"https://api.github.com/users/ramedey/orgs","repos_url":"https://api.github.com/users/ramedey/repos","events_url":"https://api.github.com/users/ramedey/events{/privacy}","received_events_url":"https://api.github.com/users/ramedey/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Microsoft/vsts-tasks/labels/Area:%20RM","name":"Area: RM","color":"5319e7"},{"url":"https://api.github.com/repos/Microsoft/vsts-tasks/labels/Dev15","name":"Dev15","color":"1d76db"}],"state":"open","locked":false,"assignee":{"login":"kmkumaran","id":11780076,"avatar_url":"https://avatars.githubusercontent.com/u/11780076?v=3","gravatar_id":"","url":"https://api.github.com/users/kmkumaran","html_url":"https://github.com/kmkumaran","followers_url":"https://api.github.com/users/kmkumaran/followers","following_url":"https://api.github.com/users/kmkumaran/following{/other_user}","gists_url":"https://api.github.com/users/kmkumaran/gists{/gist_id}","starred_url":"https://api.github.com/users/kmkumaran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kmkumaran/subscriptions","organizations_url":"https://api.github.com/users/kmkumaran/orgs","repos_url":"https://api.github.com/users/kmkumaran/repos","events_url":"https://api.github.com/users/kmkumaran/events{/privacy}","received_events_url":"https://api.github.com/users/kmkumaran/received_events","type":"User","site_admin":false},"assignees":[{"login":"kmkumaran","id":11780076,"avatar_url":"https://avatars.githubusercontent.com/u/11780076?v=3","gravatar_id":"","url":"https://api.github.com/users/kmkumaran","html_url":"https://github.com/kmkumaran","followers_url":"https://api.github.com/users/kmkumaran/followers","following_url":"https://api.github.com/users/kmkumaran/following{/other_user}","gists_url":"https://api.github.com/users/kmkumaran/gists{/gist_id}","starred_url":"https://api.github.com/users/kmkumaran/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kmkumaran/subscriptions","organizations_url":"https://api.github.com/users/kmkumaran/orgs","repos_url":"https://api.github.com/users/kmkumaran/repos","events_url":"https://api.github.com/users/kmkumaran/events{/privacy}","received_events_url":"https://api.github.com/users/kmkumaran/received_events","type":"User","site_admin":false},{"login":"rohit-batra","id":21075522,"avatar_url":"https://avatars.githubusercontent.com/u/21075522?v=3","gravatar_id":"","url":"https://api.github.com/users/rohit-batra","html_url":"https://github.com/rohit-batra","followers_url":"https://api.github.com/users/rohit-batra/followers","following_url":"https://api.github.com/users/rohit-batra/following{/other_user}","gists_url":"https://api.github.com/users/rohit-batra/gists{/gist_id}","starred_url":"https://api.github.com/users/rohit-batra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rohit-batra/subscriptions","organizations_url":"https://api.github.com/users/rohit-batra/orgs","repos_url":"https://api.github.com/users/rohit-batra/repos","events_url":"https://api.github.com/users/rohit-batra/events{/privacy}","received_events_url":"https://api.github.com/users/rohit-batra/received_events","type":"User","site_admin":false}],"milestone":null,"comments":2,"created_at":"2016-08-27T19:25:11Z","updated_at":"2016-08-31T08:08:03Z","closed_at":null,"body":"When I set /p:BackupDatabaseBeforeChanges=True I get this error (and the release doesn't fail)\r\n\r\n2016-08-27T19:10:42.0872590Z An error occurred while the batch was being executed.\r\n2016-08-27T19:10:42.0962588Z Updating database (Failed)\r\n2016-08-27T19:10:42.1112567Z *** Could not deploy package.\r\n2016-08-27T19:10:42.1112567Z Error SQL72014: .Net SqlClient Data Provider: Msg 40515, Level 15, State 1, Line 16 Reference to database and/or server name in 'master.dbo.xp_instance_regread' is not supported in this version of SQL Server.\r\n2016-08-27T19:10:42.1112567Z Error SQL72045: Script execution error.  The executed script:\r\n2016-08-27T19:10:42.1112567Z IF (DB_ID(N'$(DatabaseName)') IS NOT NULL)\r\n2016-08-27T19:10:42.1112567Z     BEGIN\r\n2016-08-27T19:10:42.1112567Z         DECLARE @rc AS INT, @fn AS NVARCHAR (4000), @dir AS NVARCHAR (4000);\r\n2016-08-27T19:10:42.1112567Z         EXECUTE @rc = [master].[dbo].[xp_instance_regread] N'HKEY_LOCAL_MACHINE', N'Software\\Microsoft\\MSSQLServer\\MSSQLServer', N'BackupDirectory', @dir OUTPUT, 'no_output';\r\n2016-08-27T19:10:42.1112567Z         IF (@rc = 0)\r\n2016-08-27T19:10:42.1112567Z             SELECT @dir = @dir + N'\\';\r\n2016-08-27T19:10:42.1112567Z         IF (@dir IS NULL)\r\n2016-08-27T19:10:42.1112567Z             BEGIN\r\n2016-08-27T19:10:42.1112567Z                 EXECUTE @rc = [master].[dbo].[xp_instance_regread] N'HKEY_LOCAL_MACHINE', N'Software\\Microsoft\\MSSQLServer\\MSSQLServer', N'DefaultData', @dir OUTPUT, 'no_output';\r\n2016-08-27T19:10:42.1112567Z                 IF (@rc = 0)\r\n2016-08-27T19:10:42.1112567Z                     SELECT @dir = @dir + N'\\';\r\n2016-08-27T19:10:42.1112567Z             END\r\n2016-08-27T19:10:42.1122591Z         IF (@dir IS NULL)\r\n2016-08-27T19:10:42.1122591Z             BEGIN\r\n2016-08-27T19:10:42.1122591Z                 EXECUTE @rc = [master].[dbo].[xp_instance_regread] N'HKEY_LOCAL_MACHINE', N'Software\\Microsoft\\MSSQLServer\\Setup', N'SQLDataRoot', @dir OUTPUT, 'no_output';\r\n2016-08-27T19:10:42.1122591Z                 IF (@rc = 0)\r\n2016-08-27T19:10:42.1122591Z                     SELECT @dir = @dir + N'\\Backup\\';\r\n2016-08-27T19:10:42.1122591Z             END\r\n2016-08-27T19:10:42.1122591Z         IF"},"comment":{"url":"https://api.github.com/repos/Microsoft/vsts-tasks/issues/comments/243690094","html_url":"https://github.com/Microsoft/vsts-tasks/issues/2350#issuecomment-243690094","issue_url":"https://api.github.com/repos/Microsoft/vsts-tasks/issues/2350","id":243690094,"user":{"login":"rohit-batra","id":21075522,"avatar_url":"https://avatars.githubusercontent.com/u/21075522?v=3","gravatar_id":"","url":"https://api.github.com/users/rohit-batra","html_url":"https://github.com/rohit-batra","followers_url":"https://api.github.com/users/rohit-batra/followers","following_url":"https://api.github.com/users/rohit-batra/following{/other_user}","gists_url":"https://api.github.com/users/rohit-batra/gists{/gist_id}","starred_url":"https://api.github.com/users/rohit-batra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rohit-batra/subscriptions","organizations_url":"https://api.github.com/users/rohit-batra/orgs","repos_url":"https://api.github.com/users/rohit-batra/repos","events_url":"https://api.github.com/users/rohit-batra/events{/privacy}","received_events_url":"https://api.github.com/users/rohit-batra/received_events","type":"User","site_admin":false},"created_at":"2016-08-31T08:08:03Z","updated_at":"2016-08-31T08:08:03Z","body":"Hello,\r\nWe have Added the fix to Solve Silent Passing issue. Task should now fail. Fix will be available post next Deployment. Please update this thread once you have verified."}}
{"actor":{"display_login":"rohit-batra"}}