unable to run athena query

0

Execute the query

response = athena.start_query_execution(QueryExecutionContext={ 'Database': 'trainingdb',}, QueryString='select * from "tainingdb.myiotdata"', ResultConfiguration={ 'OutputLocation': 's3://myiotdata01/', 'ExpectedBucketOwner':'562636776084' } )

getting the following error while executing above code from my local jupyter

SYNTAX_ERROR: line 1:15: Table awsdatacatalog.trainingdb.tainingdb.myiotdata does not exist This query ran against the "trainingdb" database, unless qualified by the query. Please post the error message on our forum or contact customer support with Query Id: 4af7ac1b-34da-43d5-8aff-7ef2408e3ff7

gefragt vor einem Jahr614 Aufrufe
1 Antwort
0

It doesn't like that you put the database in front of the table name in the query. Did you try it without that? Here's some documentation that doesn't have the database name in the query. Since it lists the database name twice in the error message and it's listed once in the query, I assume that's the cause.

https://docs.aws.amazon.com/cli/latest/reference/athena/start-query-execution.html

beantwortet vor einem Jahr

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen