- Fully managed: Interact with the table like any other RisingWave table for querying, inserting, and building materialized views.
- Open storage: Data is stored in the standard Iceberg format, ensuring compatibility with external query engines like Spark, Trino, Flink, and Dremio.
- Simplified pipelines: Ingest data from a stream directly into an Iceberg table without a separate
CREATE SINK
step to a different system.
Create an internal Iceberg table
Creating and using an internal Iceberg table is a two-step process: first, you define the storage and catalog details in aCONNECTION
object, and then you create the table itself.
Step 1: Create a connection
An IcebergCONNECTION
contains the catalog and object storage configuration. The following examples show how to create a connection for different catalog types.
These examples use S3 for object storage. For details on configuring other backends like GCS or Azure Blob Storage, see the Object storage guide. For enhanced security, you can store credentials as secrets using CREATE SECRET.
- Hosted catalog (default)
- JDBC catalog
- Glue catalog
- REST catalog
- S3 Tables catalog
For the simplest setup, use RisingWave’s built-in JDBC-based hosted catalog. This requires no external dependencies.For more details, see Hosted Iceberg catalog.
Step 2: Create the table
Create a table using theENGINE = iceberg
clause and associate it with your connection. To simplify creation, you can set a default connection for your session.
Work with internal tables
Once created, an internal Iceberg table behaves like any other table in RisingWave.Writing data
You can write data using standardINSERT
statements or by streaming data from a source using CREATE SINK ... INTO
.
Querying data
Query the table directly withSELECT
or use it as a source for a materialized view.
Time travel
Query historical snapshots of the table usingFOR SYSTEM_TIME AS OF
or FOR SYSTEM_VERSION AS OF
.
Advanced configuration
Partitioning
Define a partition strategy in theWITH
clause to optimize query performance.
bucket(n, column)
or truncate(n, column)
. The partition key must be a prefix of the primary key.
Commit interval
Control how frequently data is committed to the Iceberg table by settingcommit_checkpoint_interval
in the CONNECTION
.
Table maintenance
To maintain good performance and manage storage costs, internal Iceberg tables require periodic maintenance, including compaction and snapshot expiration. RisingWave provides both automatic and manual maintenance options. For complete details, see the Iceberg table maintenance guide.External access
Because internal tables are standard Iceberg tables, they can be read by external query engines like Spark or Trino using the same catalog and storage configuration. Spark Example:Limitations
- Limited DDL: Advanced schema evolution operations are not yet supported.
- Single writer: To ensure data consistency, only RisingWave should write to internal Iceberg tables.