raphaeldouyere opened a new issue, #14619:
URL: https://github.com/apache/iceberg/issues/14619

   ### Apache Iceberg version
   
   1.10.0 (latest release)
   
   ### Query engine
   
   Spark
   
   ### Please describe the bug 🐞
   
   We have an error when calling "rewrite_position_delete_files"
   
   The call happens in a Spark (3.5.5) session:
   `spark.sql("CALL iceberg.system.rewrite_position_delete_files( table => 
'lake.table', options => map('rewrite-all', 'true'))");`
   
   Starting with Iceberg 1.10.0 we have the following error:
   `Caused by: org.apache.iceberg.exceptions.ValidationException: Invalid 
partition field parent: list<string>
        at 
org.apache.iceberg.exceptions.ValidationException.check(ValidationException.java:49)
        at 
org.apache.iceberg.PartitionSpec.checkCompatibility(PartitionSpec.java:672)
        at 
org.apache.iceberg.PartitionSpec$Builder.build(PartitionSpec.java:628)
        at 
org.apache.iceberg.PartitionSpec$Builder.build(PartitionSpec.java:623)
        at 
org.apache.iceberg.expressions.ExpressionUtil.identitySpec(ExpressionUtil.java:656)
        at 
org.apache.iceberg.expressions.ExpressionUtil.extractByIdInclusive(ExpressionUtil.java:156)
        at 
org.apache.iceberg.spark.source.PositionDeletesRowReader.open(PositionDeletesRowReader.java:95)
        at 
org.apache.iceberg.spark.source.PositionDeletesRowReader.open(PositionDeletesRowReader.java:44)`
   
   Our tables had a partition layout change long ago and the partition spec 
currently looks like:
   `
     "default-spec-id" : 1,
     "partition-specs" : [ {
       "spec-id" : 0,
       "fields" : [ {
         "name" : "is_ok",
         "transform" : "identity",
         "source-id" : 38,
         "field-id" : 1000
       }, {
         "name" : "timestamp_hour",
         "transform" : "hour",
         "source-id" : 2,
         "field-id" : 1001
       } ]
     }, {
       "spec-id" : 1,
       "fields" : [ {
         "name" : "timestamp_hour",
         "transform" : "hour",
         "source-id" : 2,
         "field-id" : 1001
       } ]
     } ]
   `
   The code seems to break on the old "is_ok" partition.
   
   
   ### Willingness to contribute
   
   - [ ] I can contribute a fix for this bug independently
   - [ ] I would be willing to contribute a fix for this bug with guidance from 
the Iceberg community
   - [x] I cannot contribute a fix for this bug at this time


-- 
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]

Reply via email to