-
Notifications
You must be signed in to change notification settings - Fork 425
Enhanced the functionality of SqlDacPacDeploymentonOnMachineGroupV0 #1269
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
base: master
Are you sure you want to change the base?
Changes from 3 commits
4f83b14
aff349f
d2cd8fc
8c4a006
8b6b43c
adf4f83
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -87,9 +87,28 @@ function Invoke-SqlQueryDeployment | |
|
|
||
| $additionalArguments = EscapeSpecialChars $additionalArguments | ||
|
|
||
| Write-Verbose "Invoke-SqlCmd arguments : $commandToLog $additionalArguments" | ||
| Invoke-Expression "Invoke-SqlCmd @spaltArguments $additionalArguments" | ||
| $commandToRun = $commandToLog + " " + $additionalArguments | ||
| $command = "Invoke-SqlCmd @spaltArguments $additionalArguments" | ||
|
|
||
| Write-Host "##[command] $commandToRun" | ||
|
||
|
|
||
| if ($additionalArguments.ToLower().Contains("-verbose")) { | ||
|
||
| $errors = @() | ||
|
|
||
| $rawOutput = (Invoke-Expression $command -ErrorVariable errors 4>&1 | Out-String) | ||
|
||
| $trimmedOutput = $rawOutput.TrimEnd() | ||
| $trimmedOutput -split "`r?`n" | Where-Object { $_.Trim() -ne "" } | ForEach-Object { Write-Output $_ } | ||
|
|
||
| if ($errors.Count -gt 0) { | ||
| throw | ||
| } | ||
| } | ||
| else { | ||
| Invoke-Expression $command | ||
| } | ||
| } | ||
| Catch { | ||
| Write-VstsSetResult -Result 'Failed' -Message "Error detected" -DoNotThrow | ||
| } # End of Try | ||
| Finally | ||
| { | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| @{ | ||
| RootModule = 'TaskModuleSqlUtility.psm1' | ||
| ModuleVersion = '0.1.3' | ||
| ModuleVersion = '0.1.6' | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why this value? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In PS gallery, the current version of TaskModuleSqlUtility is 0.1.5, so I set the new version to 0.1.6. |
||
| GUID = 'd997c6dd-33ad-481c-859b-01120229b91f' | ||
| Author = 'Microsoft' | ||
| CompanyName = 'Microsoft' | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we consider adding this entire change under FF ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, added the entire change under the FF