Skip to main content

Our Athena Connections are configured using a specific workgroup name (rather than the default primary one).

Can I specify the workgroup name somewhere in the connection parameters?

Below is the error I receive when trying to list the named queries for this connection.

```

AmazonAthenaConnector: An error occurred while listing named queries: 'FMEException: 936005: AmazonAthenaConnector: The requested AWS operation returned an error: 'An error occurred (AccessDeniedException) when calling the ListNamedQueries operation: User: arn:aws:iam::<nr>:user/testing is not authorized to perform: athena:ListNamedQueries on resource: arn:aws:athena:eu-west-1:<nr>:workgroup/primary because no identity-based policy allows the athena:ListNamedQueries action''

```

When I try to query with a specific query it (obviously) also fails, but with a more generic error:

```

AmazonAthenaConnector: The bucket 'pnh-raw-data-euw1-s3-factsheets-output' does not exist or can not be accessed: 'An error occurred (403) when calling the HeadBucket operation: Forbidden'

```

Specifiying a workgroup name is a standard option on the driver properties of a athena jdbc connection.

For anybody interested in this issue...

I am currently using a SQLExecutor with a JDBC connection to connect to Athena.

see the fme documentation how to install a custom jdbc driver, download the athena jdbc jar from aws website and place in correct folder.

use as connection string like this: jdbc:awsathena://AWSRegion=<region>;User=<key>;Password=<secret>;Workgroup=<workgroup>;

driver class: com.simba.athena.jdbc.Driver

 


Reply