FIX: "Invoke-sqlcmd" cmdlet executes a query statement multiple times if an error occurs in SQL Server 2014 or 2016

Applies to: SQL Server 2014 DeveloperSQL Server 2014 EnterpriseSQL Server 2014 Enterprise Core


You use the invoke-sqlcmd cmdlet to execute a query statement in an instance of SQL Server 2014 or 2016. However, if execution fails because of an error, the query statement is executed multiple times.



Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.



Learn about the terminology that Microsoft uses to describe software updates.