Installing SQL RDBMS database for PAM SC 14.X gives "Msg 102, Level 15, State 1, Line 1 Incorrect syntax near 'GO'" errors and it is not properly installed.

book

Article ID: 142237

calendar_today

Updated On:

Products

CA Privileged Access Manager - Server Control (PAMSC)

Issue/Introduction

Following the documentation for installation of PAM SC 14.X ENTM on Windows, all works fine until getting to the stage of creating the MSSQL database according to

https://techdocs.broadcom.com/content/broadcom/techdocs/us/en/ca-enterprise-software/layer7-privileged-access-management/privileged-access-manager-server-control/14-1/implementing/install-ca-privileged-access-manager-server-control/prepare-the-central-database-for-installation.html

When the procedure detailed in the documentation is applied and the DB building script is run in the MSSQL Studio manager, multiple errors of the type

Msg 102, Level 15, State 1, Line 1
Incorrect syntax near 'GO'.
Msg 102, Level 15, State 1, Line 1
Incorrect syntax near 'GO'.
Msg 102, Level 15, State 1, Line 1
Incorrect syntax near 'GO'.
Msg 102, Level 15, State 1, Line 1
Incorrect syntax near 'GO'.
Msg 102, Level 15, State 1, Line 1
Incorrect syntax near 'GO'.

are thrown. As a result, the MSSQL RDBMS database is incorrectly created: not all tables exist and some are even incomplete, and the subsequent PAM SC ENTM installation is incorrect.

 

Cause

This is a known error with the 'GO' block delimiter in MSSQL Management Studio, as described in

https://stackoverflow.com/questions/9051006/sql-errorcreate-alter-procedure-must-be-the-first-statement-in-a-query-batch

The mssql_database_deployment_script.sql is lacking CRLF between the GO statements and the actual SQL statements of the blocks, which causes a failure in interpreting the syntax in MSSQL Management Studio, following the instructions given in the documentation.

 

Environment

Release : 14.X

Component : PAM SERVER CONTROL ENTM WINDOWS

Resolution

The solution consists in introducing a CRLF at the end and before each "GO" statement in the mssql_database_deployment_script.sql provided in the installation media, so that MSSQL Management Studio correctly interprets the GO statement as a separator.

Alternatively we have prepared a modified script which contains the necessary CRLF characters, which is attached to the present document

Attachments

1577126652131__mssql_database_deployment_script_2.sql get_app