Jemima Jeyakumar
Jemima Jeyakumar

Reputation: 109

Dremio ODBC with Python

Getting below error while running this code in Python, If anyone could advise me on this that would be appreciated. Thanks

dataframe = pandas.read_sql(sql,cnxn)

DatabaseError: Execution failed on sql 'SELECT * FROM train_data': ('HY000', "[HY000] [Dremio][Connector] (1040) Dremio failed to execute the query: SELECT * FROM train_data\n[30038]Query execution error. Details:[ \nVALIDATION ERROR: Table 'train_data' not found\n\nSQL Query SELECT * FROM train_data\nstartLine 1\nstartColumn 15\nendLine 1\nendColumn 24\n\n[Error Id: 24c7de0e-6e23-44c6-8cb6-b0a110bbd2fd on user:31010]\n\n (org.apache.calcite.runtime.CalciteContextException) From line 1, column 15 to line 1, column 24: ...[see log] (1040) (SQLExecDirectW)")

Upvotes: 0

Views: 1666

Answers (2)

Manish Giri
Manish Giri

Reputation: 26

You only need to provide your Space name, just before your table name. for example:

SELECT * FROM
SpaceName.train_data

This is a query to fetch data from Dremio Space, Dremio source cannot be used for data ingestion. Dremio Source only be used to establish a connection between database and Dremio.

Upvotes: 1

Jemima Jeyakumar
Jemima Jeyakumar

Reputation: 109

this is being solved, it says that table does not exist, should give a valid table, in dremio it can be inside a specific space

Upvotes: 0

Related Questions