rdblue commented on a change in pull request #2465:
URL: https://github.com/apache/iceberg/pull/2465#discussion_r615318105
##########
File path: core/src/main/java/org/apache/iceberg/SchemaUpdate.java
##########
@@ -193,6 +204,11 @@ public UpdateSchema renameColumn(String name, String
newName) {
updates.put(fieldId, Types.NestedField.of(fieldId, field.isOptional(),
newName, field.type(), field.doc()));
}
+ if (identifierFieldNames.contains(name)) {
Review comment:
I agree with this. I think it would make sense to check whether
`newName` is already a field in the schema. But that is catching a problem with
a rename earlier and isn't really related to this PR.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]