July 2018
Beginner
552 pages
13h 18m
English
The SqlServer module provides a dedicated command to run SQL commands against an instance, called Invoke-Sqlcmd. See the following example:
Invoke-Sqlcmd -ServerInstance "sql2017" -Query "SELECT 1 AS Value;"
This will execute a basic query against the default instance on sql2017. The -ServerInstance parameter accepts names, IP addresses, or connection strings.
It also handles instance server objects, as shown on the previous ...
Read now
Unlock full access