sl255051 commented on code in PR #10678: URL: https://github.com/apache/iceberg/pull/10678#discussion_r1701214301
########## api/src/main/java/org/apache/iceberg/PartitionSpec.java: ########## @@ -442,9 +456,10 @@ private Types.NestedField findSourceColumn(String sourceName) { Builder identity(String sourceName, String targetName) { Types.NestedField sourceColumn = findSourceColumn(sourceName); checkAndAddPartitionName(targetName, sourceColumn.fieldId()); + String normalizedTargetName = caseSensitive ? targetName : targetName.toLowerCase(); Review Comment: I assume you meant this. The two salient differences are 1. adding `public` to `Builder identity(String sourceName)` 2. changing `sourceColumn` type from `String` to `Types.NestedField` in `private Builder identity(String sourceColumn, String targetName))` ```Java Builder identity(String sourceName, String targetName) { return identity(findSourceColumn(sourceName), targetName); } public Builder identity(String sourceName) { Types.NestedField sourceColumn = findSourceColumn(sourceName); return identity(sourceColumn, sourceColumn.name()); } private Builder identity(Types.NestedField sourceColumn, String targetName) { checkAndAddPartitionName(targetName, sourceColumn.fieldId()); PartitionField field = new PartitionField( sourceColumn.fieldId(), nextFieldId(), targetName, Transforms.identity()); checkForRedundantPartitions(field); fields.add(field); return this; } ``` -- 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. To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org