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

KB202976: "The table 'table_name' was not found in the Warehouse Catalog" error occurs when checking the table structure from a non-default user schema name in Amazon Redshift, in MicroStrategy Analytics Enterprise 9.4.1.


Community Admin

• Strategy


This technical note documents an issue that occurs with Amazon Redshift Warehouses, when using a non-default user schema name, in MicroStrategy Analytics Enterprise 9.4.1.

SUMMARY:
This technical note documents an issue that occurs with Amazon Redshift Warehouses, when using a non-default user schema name, in Strategy Analytics Enterprise 9.4.1.
 
SYMPTOM:
A user tries to add a table to a Strategy project but is unable to view the table structure against warehouse database in Amazon Redshift:
 

ka04W000000Of5pQAC_0EM440000002CDW.jpeg

table structure error
 


The table 'table_name' was not found in the warehouse catalog. Therefore, the table structure cannot be read or updated.

 
When checking another table the information is returned without error.
The user can verify that the two tables reside in different schemas by first removing the table(s) from the project and then changing the Warehouse Catalog option to display the table name spaces, as shown below:
 

ka04W000000Of5pQAC_0EM440000002CDX.jpeg

view table namespace
 
Click OK to save the change to the Warehouse Catalog Options and then check the list of available tables. The name space (or schema) will be displayed in the list of available tables. In the example below there are two different name spaces (schemas) available to this user.

ka04W000000Of5pQAC_0EM440000002CDM.jpeg

 
A connection to the Amazon Redshift database can be made to verify the default search path used by the driver when the ODBC call to SQLColumns is made.
To check the default schema (or first in the search path) for an Amazon Redshift user, the following query can be executed from the Strategy DB query tool.


show search_path;

In this example the default path is “$user, public”.
 
CAUSE:
Strategy uses the ODBC Call of SQLColumns to obtain the column names and data types from an Amazon Redshift table. In some cases, a database user may have the privilege to access tables in a schema other than the default schema for that user. In this scenario the user will encounter an error when trying to fetch back the column information in Strategy Developer Warehouse Catalog Browser. This is due to a known issue in Strategy Analytics Enterprise 9.4.1 where the call to SQLColumns does not include the schema name and so column names and data types are not returned. 
 
ACTION:
This issue has been addressed in Strategy Analytics Enterprise 9.5. Upgrade to that version to take advantage of this fix.
 
WORKAROUND:
The preferred workaround to this issue is to create views so that the user can access the tables from the default (first in the search path) schema. If all of the tables and views reside in the default schema there will be no issue retrieving the column names and data types.
Use the Strategy DB query tool to create a view(s) of the table(s) that reside in the non-default schema. Since the Amazon Redshift user has already been granted read access to the data residing in the non-default schema there should be no error in creating the view.
For example, ‘CREATE VIEW a_test_table_v AS SELECT * FROM abc.a_test_table’.
Open the Strategy Developer Warehouse Catalog to view the newly created view and the column names and data types.
 
The Strategy Internal Reference Number for this issue discussed in this technical note is 861869.


Comment

0 comments

Details

Knowledge Article

Published:

June 8, 2017

Last Updated:

June 8, 2017