question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Not able to add a table from external Redshift Spectrum schema

See original GitHub issue
  • I have checked the superset logs for python stacktraces and included it here as text if any
  • I have reproduced the issue with at least the latest released version of superset
  • I have checked the issue tracker for the same issue and I haven’t found one similar

Superset version

0.26.3

Expected results

I want to add a table from external Redshift Spectrum schema, in order to create charts based on this table. I expect the flow will be the same as with “local” Redshift schemas:

  1. Sources -> Databases -> Add (postgresql)
  2. Sources -> Tables -> Add (select redshift DB, put schema name and table name)
  3. Observe a table in a table list

Actual results

Following error is displayed:

Table [spectrum.assoc] could not be found, please double check your database connection, schema, and table name

where spectrum is an external schema name and assoc is a table name.

Steps to reproduce

Create Redshift cluster; create external spectrum schema; add a table to the metastore

Notes

  • I think this might be a duplicate of https://github.com/apache/incubator-superset/issues/3316
  • In psql console, you can’t get a list of tables in external spectrum schema by using \dS, only by querying SVV_EXTERNAL_TABLES system view.
  • In Superset’s SQL Lab I can query external spectrum tables by using schema.tablename naming

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:9 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
RodBartcommented, Jan 26, 2021

another workaround, could be create a table in a local schema whit the same structure as the table in external schema, then import the new table and finaly change the schema in superset for the external schema, it worked for me.

Can you explain more on how you import the new table and change the schema in superset for the external echema? Do you mean by import the table in the local schema into superset. Then edit the dataset and change the schema to the external schema? Thanks!

Yes, exactly

0reactions
blackhawk28commented, Jun 28, 2021

hi @RodBart and @robert-yxin05 I need some clarification, where did you create the table in redshift? and in local schema? and then import that table with the local schema in superset then change its schema to external? and the table which we’ll create in local schema, its name should be same as of external_table right?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Creating external tables for Redshift Spectrum
You create an external table in an external schema. To create external tables, you must be the owner of the external schema or...
Read more >
Not able to add a table from external Redshift Spectrum ...
I want to add a table from external Redshift Spectrum schema, in order to create charts based on this table. I expect the...
Read more >
cannot create a view in redshift spectrum external schema
You can create a view on top of external tables (WITH NO SCHEMA BINDING clause), but the view will reside in a schema...
Read more >
Step 3: Create an external schema and an external table
To create an external schema, replace the IAM role ARN in the following command with the role ARN you created in step 1....
Read more >
Don't see tables in external schemas (Redshift Spectrum)
I can create view but i can't access it because of “Invalid operation: Nested tables do not support '*' in the SELECT clause.”...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found