RussellSpitzer commented on a change in pull request #2953:
URL: https://github.com/apache/iceberg/pull/2953#discussion_r712407035
##########
File path: parquet/src/main/java/org/apache/iceberg/parquet/PruneColumns.java
##########
@@ -49,7 +51,16 @@ public Type message(MessageType message, List<Type> fields) {
Type field = fields.get(i);
Integer fieldId = getId(originalField);
if (fieldId != null && selectedIds.contains(fieldId)) {
- builder.addField(originalField);
+ if (field != null) {
+ hasChange = true;
+ builder.addField(field);
+ } else {
+ if (isStruct(originalField)) {
+
builder.addField(originalField.asGroupType().withNewFields(Collections.emptyList()));
Review comment:
Changing the ordering of the statements under (field != null) so that
they match the usages here
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]