Installing Service Catalog 17.1.0.1 without SQL Server Management Studio

Document ID : KB000100129
Last Modified Date : 05/06/2018
Show Technical Document Details
Question:
The post install task for the Service Management 17.1.0.1 patch involves running a SQL Server script. The documentation says use SQL Server Management Studio, we don't have this installed, we have SQL Server Client Tools. How to we run this script?
Answer:
You can use sqlcmd to run a sql server script on a remote SQL Server. To do this, the command syntax is:

sqlcmd -S <hostname> -U <username> -P <password> -d <database> -i <script file>

so the post installation command would be:

sqlcmd -S sqlserver -U mdbadmin -P mbadminpassword -d mdb -i configureMSSQLMDB-SP2.sql