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

preguntada hace un año614 visualizaciones
1 Respuesta
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

respondido hace un año

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas