Incorrect syntax or Reserved word errors when administering databases hosted on SQL Server 2005 or 2008

Technote (troubleshooting)


Problem(Abstract)

This technote explains "Incorrect syntax" or "Reserved word" errors that can occur when moving or creating IBM Rational ClearQuest databases on Microsoft SQL Server 2005 or 2008.

Symptom

Creating a schema repository or user database with the destination as a SQL Server 2005 back end database prompts this error:


    SQLExecDirect: RETCODE=-1, State=37000, Native Error=-3504
    SQL statement='select from master_global'
    [Microsoft][ODBC Microsoft Access Driver]The SELECT statement includes a reserved word or an argument name that is misspelled or missing, or the punctuation is incorrect.

These similar error messages can also occur:

    SQLExecDirect: RETCODE=-1, State=37000, Native Error=156
    SQL statement="select from master_global"
    [Microsoft][ODBC SQL Server Driver][SQL Server]Incorrect syntax near the keyword 'from'.


    CRMDB001E SQLExecDirect: RETCODE=-1, State=37000, Native Error=-3504
    [Microsoft][ODBC Microsoft Access Driver]The SELECT statement includes a reserved word or an argument name that is misspelled or missing, or the punctuation is incorrect.
    SQL statement="select from master_global"

Cause

There are two configuration problems with using SQL Server 2005 or 2008 that cause this problem:
1. The Default Schema name of the SQL Server login does not match that of the User Name.
2. The sa account is being used in the Maintenance Tool connection or the User Database Properties in Designer, rather than the login account created in SQL Server.


Resolving the problem

Resolving Cause 1

The SQL Server login account of the database must be set to use a Default Schema name that is the same as the account User Name. To change the Default Schema name of an account, start the SQL Server Management Console.

  1. Select the database being used.
  2. Open the Users tree in that database. If the intended login account is already in that list, change its Default Schema to be the same as the User Name. Otherwise, add the user with a Default Schema that is the same as the User Name, and give it the db_owner role for this database.



No Server Roles should exist for the login account. This will cause problems with authentication even with correctly configured roles and associations.

Resolving Cause 2

You cannot use the sa account as a login for use with ClearQuest. Use a separate account configured using the instructions in the ClearQuest installation documentation.



Note: If these steps do not resolve the issue, it could be necessary to re-create the databases or user accounts in accordance to the documentation instructions. For more information on the process in full, refer to Chapter 2 of the Installation and Upgrade Guides, or the Microsoft SQL Server configuration topic of the ClearQuest Knowledge Center.


Cross reference information
Segment Product Component Platform Version Edition
Software Development Rational ClearQuest Designer - Database Administration
Software Development Rational ClearQuest Maintenance tool

Rate this page:

(0 users)Average rating

Add comments

Document information


More support for:

Rational ClearQuest
Database Configuration/Connectivity - SQL Server

Software version:

7.0, 7.1

Operating system(s):

Windows

Reference #:

1239777

Modified date:

2009-05-18

Translate my page

Machine Translation

Content navigation