RTC CQ connector synctool failed
![](http://jazz.net/_images/myphoto/1b25259616339b366c1a22e15475bd99.jpg)
after running the synctool from command line, we got the following error message
synctool recordType="Work_Request" jazzServer="https://XXX:XXX@XXX:9443/ccm" projectArea="CQ Synch Sandbox"
1 file(s) copied.
The SyncTool has started...
The SyncTool is trying to login to https://XXX:9443/ccm ...
The SyncTool has logged into the CQ IXA_CLONE/IXA schema repository/user database.
09 Dec 2010 11:51:36,229 ERROR com.ibm.rational.synctool - CRVAP0021E (conflict): Execution of query 'Work_RequestdoQuery(...)' failed.
...com.rational.clearquest.cqjni.CQException: Caught a CQException at the JNI Boundary:
\bugbert.src\cqobjectmodel\cqresultset.cpp: line 179-SQLExecDirect: RETCODE=-1, State=37000, Native Error=106
Too many table names in the query. The maximum allowable is 256.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
synctool recordType="Work_Request" jazzServer="https://XXX:XXX@XXX:9443/ccm" projectArea="CQ Synch Sandbox"
1 file(s) copied.
The SyncTool has started...
The SyncTool is trying to login to https://XXX:9443/ccm ...
The SyncTool has logged into the CQ IXA_CLONE/IXA schema repository/user database.
09 Dec 2010 11:51:36,229 ERROR com.ibm.rational.synctool - CRVAP0021E (conflict): Execution of query 'Work_RequestdoQuery(...)' failed.
...com.rational.clearquest.cqjni.CQException: Caught a CQException at the JNI Boundary:
\bugbert.src\cqobjectmodel\cqresultset.cpp: line 179-SQLExecDirect: RETCODE=-1, State=37000, Native Error=106
Too many table names in the query. The maximum allowable is 256.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
Incorrect syntax near ')'.
3 answers
![](http://jazz.net/_images/myphoto/1b25259616339b366c1a22e15475bd99.jpg)
The above error was caused because Clear Quest was attempting to gather information from too many tables at once (more than 256)
With this case, many CQ fields with empty values had been mapped to RTC fields within the synchronization rules. The customer expected them to simply map over blankly to RTC, but CQ was instead being forced to look through and retrieve all the tables containing these attributes. Because of this, CQ was overriding (or possibly adding to) the original query and searching through too many tables.
After removing all excess CQ fields in the synchronization rules, the query worked without a problem.
__________________________
Benjamin Kane
Jazz/RTC Service and Support
With this case, many CQ fields with empty values had been mapped to RTC fields within the synchronization rules. The customer expected them to simply map over blankly to RTC, but CQ was instead being forced to look through and retrieve all the tables containing these attributes. Because of this, CQ was overriding (or possibly adding to) the original query and searching through too many tables.
After removing all excess CQ fields in the synchronization rules, the query worked without a problem.
__________________________
Benjamin Kane
Jazz/RTC Service and Support
![](http://jazz.net/_images/myphoto/1b25259616339b366c1a22e15475bd99.jpg)
Thanks Ben for resolving this. The CQ Connector retrieves the fields specified in the sync rules by modifying the original query's list of display fields and adding the corresponding tables and filters. I'm confused by the expectation to simply map over empty values. How would the CQ Connector know that those values are empty if it doesn't try to retrieve them from the db by executing a query.