EducationSoftwareStrategy.com
StrategyCommunity

Knowledge Base

Product

Community

Knowledge Base

TopicsBrowse ArticlesDeveloper Zone

Product

Download SoftwareProduct DocumentationSecurity Hub

Education

Tutorial VideosSolution GalleryEducation courses

Community

GuidelinesGrandmastersEvents
x_social-icon_white.svglinkedin_social-icon_white.svg
Strategy logoCommunity

© Strategy Inc. All Rights Reserved.

LegalTerms of UsePrivacy Policy
  1. Home
  2. Topics

KB439428: "It contains two or more catalog instances with the same database role ID ('XXX')" error message is displayed when using JDBC connection


Community Admin

• Strategy


This knowledge base article describes an issue that occur in MicroStrategy Web Data Import when connecting to Amazon RedShift using JDBC connection, user get "The catalog collection is not well formed. It contains two or more catalog instances with the same database role ID ('XXX')" error message. The impact is limited to using Amazon RedShift native JDBC driver. Two workarounds are provided.

SYMPTOM:
In Strategy Web 10.x, after creating a data source via Data Import using JDBC connection, when users try to access available tables in the Amazon RedShift database by clicking the data source, the below error message is displayed:

ka04W000000Ob86QAC_0EM44000000QDSl.png

If users click OK, then manually search for a table in the Available Tables search dialog, the table is returned and can use the table without any issues.

ka04W000000Ob86QAC_0EM44000000QDSq.png

CAUSE:
This issue is caused by the Amazon RedShift JDBC native driver not following the JDBC call convention when retrieving the table namespaces. Strategy call "DatabaseMetadata.getTables("", "%","",null)" and expect to get all namespaces. But we get "DatabaseMetadata.getTables(null,null,null,null)" from the Amazon RedShift JDBC native driver which returns information of all tables. 
ACTION:
To fix this issue, add the parameter <PROPERTY NAME="CatalogNameSpaceSQL" VALUE="SELECT DISTINCT TABLE_SCHEMA as NAME_SPACE FROM INFORMATION_SCHEMA.TABLES" /> to the Amazon RedShift DBMS object in the DATABASE.pds file and re-import the Amazon RedShift DBMS object using Developer to update the metadata to make it work for 10.7 and below.
Note: Starting in version 10.8, The '[Edit Catalog Options]' is now exposed for JDBC connections. Users in this version can edit this option and directly add the sql "SELECT DISTINCT TABLE_SCHEMA as NAME_SPACE FROM INFORMATION_SCHEMA.TABLES" into the 'Retrieve namespaces available in data source' section to fix the issue without having to modify the DATABASE.pds.

ka04W000000Ob86QAC_0EM44000000QDSv.png

KB439428 KB439428


Comment

0 comments

Details

Knowledge Article

Published:

December 29, 2017

Last Updated:

December 31, 2018