Before you begin
- Permission to create S3 buckets and IAM access keys in your AWS account.
- The AWS region of your Athena data.
- Permission to add data connections in Datafold.
Set up Athena
1
Create an S3 bucket
Datafold uses this bucket to store the data of the temporary tables it creates. If you don’t already have a bucket for Athena, create one. See Creating a bucket in the AWS documentation.
2
Create an access key
Create an AWS access key ID and secret access key for Datafold. The IAM user or role behind the key needs:
- Athena permissions to run queries, for example
athena:StartQueryExecution,athena:GetQueryExecution,athena:GetQueryResultsandathena:StopQueryExecutionon your workgroup. - AWS Glue Data Catalog read access to the databases and tables in scope, and write access (
glue:CreateTable,glue:DeleteTable,glue:UpdateTable) to the temporary schema you create in the next step. - S3 read access to the buckets that hold your table data, and read and write access to the bucket you created in the previous step.
3
Create a temporary schema
Datafold writes scratch tables to this schema so that data processing stays in your warehouse. In the Athena query editor, select the
AwsDataCatalog data source and run:Network access
If your AWS resources only accept connections from allowlisted IP addresses or are only reachable over a private network, see Securing connections for the options Datafold supports.Add the connection in Datafold
Go to Settings → Integrations → Data Connections, click Add new integration and choose Amazon Athena.
Click Save.
