You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by GitBox <gi...@apache.org> on 2022/08/01 18:26:42 UTC

[GitHub] [iceberg] RussellSpitzer commented on pull request #5395: API: Assign the right field ids when merging schema, #5394

RussellSpitzer commented on PR #5395:
URL: https://github.com/apache/iceberg/pull/5395#issuecomment-1201556939

   @rdblue Just to note this is still actually incorrect as we are using the `table.currentSchema.highestId` and not `table.allschemas.highestId`. But that fix is going to take a bit more refactoring. This is what I originally guessed the issue was when this got reported to us.
   
   Imagine I have 
   `{A: 1, B: 2, C:3}`
   
   And then a user drops C so I have
   `{A: 1, B: 2} Highest Field ID = 3`
   
   Then we do a mergeSchema with
   `{A, B, D}`
   
   I will end up assigning highest( {A:1, B:2) + 1} to D
   ```
   Schemas {
   {A: 1, B: 2, C: 3}
   {A: 1, B :2, D: 3}
   }
   ```
   
   I still think we should merge this fix first as it corrects monotonically changing tables


-- 
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-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org