risingwavelabs/risingwave · error

ALTER TABLE {} is not supported for iceberg table without au

Error message

ALTER TABLE {} is not supported for iceberg table without auto schema change sink: {}.{}

What it means

ALTER TABLE ADD COLUMN on an Iceberg source table is only allowed when the table's sink supports automatic schema-change refresh. Without such a sink (`has_auto_refresh_schema_sink == false`), adding a column cannot propagate the schema change to Iceberg, so the frontend rejects the operation.

Source

Thrown at src/frontend/src/handler/mod.rs:1738

                name,
                has_auto_refresh_schema_sink,
            )?;
        }
    }

    Ok(())
}

fn check_ban_alter_table_operation_for_iceberg_engine_table(
    operation: &AlterTableOperation,
    schema_name: &str,
    table_name: &ObjectName,
    has_auto_refresh_schema_sink: bool,
) -> Result<()> {
    match operation {
        AlterTableOperation::AddColumn { .. } => {
            if !has_auto_refresh_schema_sink {
                bail!(
                    "ALTER TABLE {} is not supported for iceberg table without auto schema change sink: {}.{}",
                    operation,
                    schema_name,
                    table_name
                );
            }
        }
        AlterTableOperation::DropColumn { .. } => {
            if !has_auto_refresh_schema_sink {
                bail!(
                    "ALTER TABLE {} is not supported for iceberg table without auto schema change sink: {}.{}",
                    operation,
                    schema_name,
                    table_name
                );
            }
        }
        AlterTableOperation::RenameColumn { .. }

View on GitHub (pinned to 6469eb736d)

Solutions

  1. Recreate the Iceberg sink with auto schema-change support enabled (auto refresh schema sink option), then retry ALTER TABLE ADD COLUMN.
  2. Evolve the schema on the Iceberg side (or via the connector) instead of RisingWave ALTER TABLE.
  3. Drop and recreate the table/sink with the new schema and backfill if schema evolution is essential.

Example fix

// before
CREATE SINK s FROM t WITH (connector = 'iceberg', ...); -- no auto schema change
ALTER TABLE t ADD COLUMN c INT;
// after
CREATE SINK s FROM t WITH (connector = 'iceberg', auto_refresh_schema = true, ...);
ALTER TABLE t ADD COLUMN c INT;
Defensive patterns

Strategy: validation

Validate before calling

-- Confirm the iceberg sink supports auto schema change before ADD COLUMN
SELECT * FROM rw_catalog.rw_sinks
WHERE sink_from_relation_name = 't';
-- verify the sink properties include auto schema-change refresh

Type guard

fn supports_auto_schema_change(sink_props: &SinkProps) -> bool {
    sink_props.auto_refresh_schema == Some(true)
}

Try / catch

match client.alter_table_add_column(table, col).await {
    Err(e) if e.message().contains("without auto schema change sink") => {
        // recreate sink with auto_refresh_schema before retrying
    }
    other => other?,
}

Prevention

When it happens

Trigger: Executing `ALTER TABLE <iceberg_table> ADD COLUMN ...` on a table backed by an Iceberg sink that was not created with auto schema-change support (e.g. missing the auto-refresh-schema sink option).

Common situations: Iceberg sink created before auto schema change was available or without the required sink option; schema evolution attempted manually on a legacy Iceberg table.

Related errors


AI-assisted analysis of risingwavelabs/risingwave@6469eb736d (2026-09-11). Data as JSON: /api/errors/2b9ee31b3a1adec7. Report an issue: GitHub.