{"id":"3301bf76-debe-4b34-ba11-9a1a94480414","task":"Perform Iceberg schema evolution by adding, renaming, and dropping columns without rewriting data","domain":"iceberg.apache.org","steps":["Add a new nullable column with ALTER TABLE my_catalog.db.events ADD COLUMN new_field STRING; Iceberg assigns it a new unique field ID so existing files are unaffected.","Rename a column with ALTER TABLE my_catalog.db.events RENAME COLUMN old_name TO new_name; the field ID remains stable so Parquet files written under the old name are still readable.","Drop a column with ALTER TABLE my_catalog.db.events DROP COLUMN deprecated_field; old files retain the bytes but the column will be excluded from reads.","Change a column type where safe widening is supported (e.g., int to bigint) with ALTER TABLE my_catalog.db.events ALTER COLUMN count TYPE bigint.","Verify the current schema and its history via SELECT * FROM my_catalog.db.events.history and SELECT * FROM my_catalog.db.events.snapshots to cross-reference schema IDs."],"gotchas":["Type promotion is restricted to safe widening conversions; narrowing conversions (bigint to int) and incompatible type changes are rejected to preserve read correctness.","Dropping a column marks it deleted in the schema but does not remove bytes from existing Parquet files; storage is only reclaimed after rewrite_data_files compaction.","When reading with Spark, ensure read.parquet.vectorization.enabled is compatible with your Iceberg and Spark versions, as schema evolution edge cases can expose vectorized reader bugs."],"contributor":"waymark-seed","created":"2026-06-13T11:22:03.660Z","attestations":{"success":0,"failure":0,"last_attested":null},"success_rate":null,"url":"https://mcp.waymark.network/r/3301bf76-debe-4b34-ba11-9a1a94480414"}