Skip to content

Commit ec001fd

Browse files
author
Travis Fields
committed
Fix bug with TSQL provider rework
1 parent ffadfd2 commit ec001fd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/puppet/templates/authenticated_query.ps1.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ if (!(Get-Command 'sqlcmd.exe' -ErrorAction SilentlyContinue)){
2424
}
2525

2626
$result = sqlcmd.exe -i '<%= input_file %>' -h-1 -W -s ',' <% if @instance != 'MSSQLSERVER' %>-S localhost\<%= @instance %><%end%>
27-
if($result -match "ERROR"){
27+
if($result -match "THROW CAUGHT"){
2828
Write-Host ($result | where {$_ -match "THROW CAUGHT"} | select -First 1)
2929
Write-Error -Message ($result | where {$_ -match "THROW CAUGHT"} | select -First 1)
3030
exit(10)

0 commit comments

Comments
 (0)