Athena Database

Can you tell me why using this sql command to select all rows from a an AWS athena database

"SELECT * FROM xxxxxxxxxxxxxxx.table1")

gives me this error ?

Error: HIVE_BAD_DATA: Field mojap_max_overview_date's type INT32 in parquet file yyyyyyyyyyyyyyyyyyyyyyyyy .parquet is incompatible with type varchar defined in table schema

I have never seen this of course when I just run a standard sql query in SQL server

Check the correct name of data base. Verify the conection.

The error message indicates, the problem is not with the connection nor the table name but with an incompatible data type in the mojap_max_overview_date column, I have never used Athena but like with many other RDBMS I suppose it is possible to cast the variable into varchar as a walk-around, ideally you should formally report the issue to the maintainer of the driver you are using so they can make sure the data type conversion is handled correctly by the driver.

1 Like

Thanks for the heads up

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.