⌘+k ctrl+k
1.2.1 (stable)
Search Shortcut cmd + k | ctrl + k
Amazon S3 Tables

The iceberg extension supports reading Iceberg tables stored in Amazon S3 Tables.

Requirements

The S3 Tables support is currently experimental. To use it, install the following extensions:

FORCE INSTALL aws FROM core_nightly;
FORCE INSTALL httpfs FROM core_nightly;
FORCE INSTALL iceberg FROM core_nightly;

If you want to switch back to using extensions from the core repository, follow the extension documentation.

Connecting to Amazon S3 Tables

You can let DuckDB detect your AWS credentials and configuration based on the default profile in your ~/.aws directory by creating the following secret using the Secrets Manager:

CREATE SECRET (
    TYPE s3,
    PROVIDER credential_chain
);

Alternatively, you can set the values manually:

CREATE SECRET (
    TYPE s3,
    KEY_ID '⟨YOUR_ACCESS_KEY_ID⟩',
    SECRET '⟨YOUR_SECRET_ACCESS_KEY⟩',
    REGION '⟨YOUR_DEFAULT_REGION⟩'
);

Then, connect to the catalog using you S3 Tables ARN (available in the AWS Management Console) and the ENDPOINT_TYPE s3_tables option:

ATTACH '⟨s3_tables_arn⟩' AS s3_tables (
   TYPE iceberg,
   ENDPOINT_TYPE s3_tables
);

To check whether the attachment worked, list all tables:

SHOW ALL TABLES;

You can query a table as follows:

SELECT count(*)
FROM s3_tables.namespace_name.table_name;