Amazon Athena

Amazon Athena

Beta
Beta release

This source is currently in beta. It works end to end, but you may still hit rough edges. Let us know if you do.

Let AI connect your sources for you

Skip the manual setup — run this in your project and the wizard auto-detects your databases and APIs and connects them to PostHog.

Learn more
PostHog Wizard hedgehog

Connect Amazon Athena to PostHog to sync your data into the PostHog data warehouse for analysis and modeling.

Sync tables from an AWS Glue database through Amazon Athena into the PostHog Data warehouse.

Create an IAM user or role with glue:GetDatabase, glue:GetTables, glue:GetTable, glue:GetPartitions, glue:GetPartition, glue:BatchGetPartition, athena:GetWorkGroup, athena:StartQueryExecution, athena:GetQueryExecution, athena:GetQueryResults and athena:StopQueryExecution, plus read access to the tables' S3 data and read and write access to the query result location. Paste its access key ID and secret access key.

Each sync runs one Athena query per table, which Athena bills by the data it scans. An incremental sync filters on the chosen column, so a partitioned table keyed on that column scans less.

Configuration

OptionTypeRequired
AWS access key IDtextYes
AWS secret access keypasswordYes
AWS session token (only for temporary credentials)passwordNo
AWS regiontextYes
Glue databasetextYes
Athena workgroup (defaults to primary)textNo
S3 output location (only when the workgroup has none)textNo

Linking Amazon Athena to PostHog

  1. Go to the Data pipeline page in PostHog
  2. Click New source and select Amazon Athena
  3. Fill in the required configuration fields
  4. Click Next, select the tables you want to sync, and then press Import

Supported tables

The tables available from this source are discovered from your account when you connect it, so the exact list depends on your data. Once connected, you can pick which tables to sync from the sources tab.