Skip to content

Commit 8e2938b

Browse files
committed
fix: do not remove new columns values
1 parent 11b3bf9 commit 8e2938b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

awswrangler/athena/_write_iceberg.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -548,7 +548,7 @@ def to_iceberg( # noqa: PLR0913
548548

549549
# Ensure that the ordering of the DF is the same as in the catalog.
550550
# This is required for the INSERT command to work.
551-
df = df[catalog_cols]
551+
df = df[catalog_cols + [col_name for col_name, _ in schema_differences["new_columns"].items()]]
552552

553553
if schema_evolution is False and any([schema_differences[x] for x in schema_differences]): # type: ignore[literal-required]
554554
raise exceptions.InvalidArgumentValue(f"Schema change detected: {schema_differences}")

0 commit comments

Comments
 (0)