You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Details of the scenario you try and problem that is occurring:
When PowerShell 4,0 is installed calling Invoke-Sqlcmd from the helper function Invoke-SqlScript fails.
See more detailed explanation here: #252 (comment)
If there is no solution to running this resource using PowerShell 4.0, then as a minimum we have to document in the README.md that this is PowerShell 5.0 only.
The DSC configuration that is using the resource (as detailed as possible):
Configuration
select name fromsys.databaseswhere name ='MyScriptDatabase1'
Set-RunSQLScript.sql
CREATE DATABASE [MyScriptDatabase1]
Test-RunSQLScript.sql
if (selectcount(name) fromsys.databaseswhere name ='MyScriptDatabase1') =0BEGIN
RAISERROR ('Did not find database [MyScriptDatabase1]', 16, 1)
END
ELSE
BEGIN
PRINT 'Found database [MyScriptDatabase1]'
END
Version of the Operating System, SQL Server and PowerShell the DSC Target Node is running:
Windows Server 2012 R2, SQL Server 2014, PowerShell 4.0
Version of the DSC module you're using, or 'dev' if you're using current dev branch:
Dev
The text was updated successfully, but these errors were encountered:
johlju
added
bug
The issue is a bug.
help wanted
The issue is up for grabs for anyone in the community.
in progress
The issue is being actively worked on by someone.
and removed
help wanted
The issue is up for grabs for anyone in the community.
labels
Dec 30, 2016
Details of the scenario you try and problem that is occurring:
When PowerShell 4,0 is installed calling
Invoke-Sqlcmd
from the helper functionInvoke-SqlScript
fails.See more detailed explanation here:
#252 (comment)
If there is no solution to running this resource using PowerShell 4.0, then as a minimum we have to document in the README.md that this is PowerShell 5.0 only.
The DSC configuration that is using the resource (as detailed as possible):
Configuration
Get-RunSQLScript.sql
Set-RunSQLScript.sql
Test-RunSQLScript.sql
Version of the Operating System, SQL Server and PowerShell the DSC Target Node is running:
Windows Server 2012 R2, SQL Server 2014, PowerShell 4.0
Version of the DSC module you're using, or 'dev' if you're using current dev branch:
Dev
The text was updated successfully, but these errors were encountered: