Skip to main content

Tableau

Tableau connects to a database through a connector, live or as an extract. Connect it to the engine that already reads your Send2Bucket data, and expose flat views rather than the raw envelope: Tableau's drag-and-drop fields cannot reach inside a JSON column.

You haveTableau connector
Athena over the bucket or S3 TablesAmazon Athena
BigQueryGoogle BigQuery
Trino or StarburstStarburst Enterprise, with the Trino JDBC driver
SnowflakeSnowflake
RedshiftAmazon Redshift
Records loaded into PostgreSQLPostgreSQL
MotherDuckPostgreSQL, to MotherDuck's Postgres endpoint, or the DuckDB JDBC driver
note

This page follows the documentation of Tableau, Starburst and MotherDuck. The steps in Tableau were not run by us. The SQL is from the engine pages, where we ran it against our sample data.

Flat views​

Create one view per signal in the engine, with the fields people chart as columns. Tableau then sees typed dimensions and measures. For example, in Athena or Trino, over the Iceberg table:

CREATE VIEW s2b.events_flat AS
SELECT ingested_at,
json_extract_scalar(payload, '$.data.event') AS event,
json_extract_scalar(payload, '$.data.user_id') AS user_id,
CAST(json_extract_scalar(payload, '$.data.cents') AS bigint) AS cents
FROM s2b.events
WHERE signal_type = 'event';

In PostgreSQL, use the s2b_events view from Metabase. In BigQuery, use JSON_VALUE on s2b.records in the same way. Grant the Tableau user SELECT on the views only.

For a one-off analysis, New Custom SQL in the data source pane accepts any query from the engine page instead.

Connectors​

  • Amazon Athena: install the Athena JDBC driver into Tableau's Drivers folder. The connection needs the Athena endpoint for your region, the S3 staging directory for query results, and an access key or IAM role that can run queries in the workgroup and read the Send2Bucket prefix. Every refresh of a live connection runs Athena queries that scan data, so filter on date and prefer extracts for dashboards over many days.
  • Google BigQuery: sign in with a Google account or a service account key that has BigQuery Data Viewer on the s2b dataset and BigQuery Job User on the billing project.
  • Starburst Enterprise: works with Trino too. Put the Trino JDBC driver JAR in Tableau's Drivers folder and keep only one Trino JDBC version there. Fill in host, port (443 with TLS), catalog and schema, and a read-only user.
  • Snowflake, Amazon Redshift, PostgreSQL: built in. Use a role or user with SELECT on the Send2Bucket views only. See Redshift and PostgreSQL for the tables.

DuckDB and MotherDuck​

For views kept in MotherDuck:

  • Tableau Cloud: add a PostgreSQL connection to MotherDuck's Postgres endpoint, with a read-scoped MotherDuck token as the password. Queries are DuckDB SQL, so the DuckDB example queries work as Custom SQL.
  • Tableau Desktop and Server: MotherDuck documents a setup with the DuckDB JDBC driver and a Tableau connector file, which also reads a local DuckDB database file. Follow MotherDuck's Tableau guide for the current driver and connector versions.

Notes​

  • A Live connection queries the engine every time a view is opened or filtered. An Extract copies the result into Tableau and refreshes on the schedule you set in Tableau Cloud or Tableau Server. For bucket destinations, which are slow to scan, extracts on a schedule cost less and load faster.
  • Tableau Cloud reaches databases on the public internet. For an engine inside a private network, use Tableau Bridge.
  • OTLP attributes are lists of key and value pairs and timestamps are nanosecond strings. Extract them in the view, as in the engine pages, not in Tableau calculations.