apache/seatunnel · warning
Column {} already exists in table {}. Skipping add column op
Error message
Column {} already exists in table {}. Skipping add column operation. event: {} What it means
SchemaUtils.applySchemaChange logs this warning when an AlterTableAddColumnEvent arrives for a column that already exists in the StarRocks table. It checks with columnExists() before executing the ALTER TABLE ADD COLUMN statement, and if the column is already present it skips the DDL and returns instead of failing the schema-change synchronization. This makes add-column events idempotent across repeated deliveries.
Source
Thrown at seatunnel-connectors-v2/connector-starrocks/src/main/java/org/apache/seatunnel/connectors/seatunnel/starrocks/util/SchemaUtils.java:92
&& columnExists(
connection,
tablePath,
changeColumnEvent.getColumn().getName())) {
log.warn(
"Column {} already exists in table {}. Skipping change column operation. event: {}",
changeColumnEvent.getColumn().getName(),
tablePath.getFullName(),
event);
return;
}
}
applySchemaChange(connection, tablePath, changeColumnEvent);
} else if (event instanceof AlterTableModifyColumnEvent) {
applySchemaChange(connection, tablePath, (AlterTableModifyColumnEvent) event);
} else if (event instanceof AlterTableAddColumnEvent) {
AlterTableAddColumnEvent addColumnEvent = (AlterTableAddColumnEvent) event;
if (columnExists(connection, tablePath, addColumnEvent.getColumn().getName())) {
log.warn(
"Column {} already exists in table {}. Skipping add column operation. event: {}",
addColumnEvent.getColumn().getName(),
tablePath.getFullName(),
event);
return;
}
applySchemaChange(connection, tablePath, addColumnEvent);
} else if (event instanceof AlterTableDropColumnEvent) {
AlterTableDropColumnEvent dropColumnEvent = (AlterTableDropColumnEvent) event;
if (!columnExists(connection, tablePath, dropColumnEvent.getColumn())) {
log.warn(
"Column {} does not exist in table {}. Skipping drop column operation. event: {}",
dropColumnEvent.getColumn(),
tablePath.getFullName(),
event);
return;
}
applySchemaChange(connection, tablePath, dropColumnEvent);View on GitHub (pinned to cf67b549a7)
Solutions
- No action required if the column already has the desired type — the operation is safely skipped.
- Verify the existing column type in StarRocks (DESC <table>) matches the intended schema; if it differs, run a manual ALTER TABLE MODIFY COLUMN.
- Check whether upstream CDC is re-emitting old schema-change events and deduplicate if replays are frequent.
Defensive patterns
Strategy: validation
Validate before calling
// before applying add-column event
try (Statement st = connection.createStatement();
ResultSet rs = st.executeQuery("DESC " + tablePath.getFullName())) {
while (rs.next()) {
if (rs.getString("Field").equalsIgnoreCase(addColumnEvent.getColumn().getName())) {
return; // already exists, skip
}
}
} Prevention
- Treat add-column warnings as idempotent skip, not failure
- Compare existing column types with the event schema after each skip
- Deduplicate CDC schema-change events before applying
When it happens
Trigger: applySchemaChange(connection, tablePath, AlterTableAddColumnEvent) is called and columnExists(connection, tablePath, columnName) returns true — i.e. the target StarRocks table already has a column with the event's column name.
Common situations: Schema change events replayed after a checkpoint/job restart; the same add-column DDL was applied manually or by another sync tool (e.g. Flink CDC pipeline); duplicate events from upstream CDC because the source schema change was applied twice.
Related errors
- Column {} already exists in table {}. Skipping change column
- Column {} does not exist in table {}. Skipping drop column o
- Failed connecting to %s via JDBC.
- Unsupported schemaChangeEvent : " + event.getEventType()
- checkpointId is already set
AI-assisted analysis of apache/seatunnel@cf67b549a7 (2026-09-10).
Data as JSON: /api/errors/baf66bea4d434f78.
Report an issue: GitHub.