openinx commented on pull request #2354:
URL: https://github.com/apache/iceberg/pull/2354#issuecomment-809869373


   > basically the row key information at that point of time is already in the 
delete file written at that time.  
   
   @jackye1995 @rdblue  Yes,  I can understand that we've maintained the 
equality field ids inside each equality delete files and iterating records from 
an old snapshot should be correct because we've considered [applying 
process](https://github.com/apache/iceberg/blob/90225d6c9413016d611e2ce5eff37db1bc1b4fc5/data/src/main/java/org/apache/iceberg/data/DeleteFilter.java#L126)
 for different equality fields ids. 
   
   But in this 
[comment](https://github.com/apache/iceberg/pull/2354#issuecomment-809033279), 
I'm not discussing the data correctness (the data correctness has no problem).  
I mean people should be able to read the old `RowKey` from an older snapshot. 
In this issue https://github.com/apache/iceberg/issues/1029,  we are proposing 
to attach the `schema` in snapshot so that users could create a complete table 
based on an existing snapshot by using CTAS or RTAS, in this scenarios I think 
we also need to use the old `PartitionSpec`, `SortOrder`, `RowKey` in the newly 
created table.  Then at the iceberg table level,  people could see the 
consistent table metadata.
   
   Another case is rollback to an older snapshot by replacing the latest 
snapshot,  though we currently do not support replacing 
schema/partition-spec/sort-order with the old one,  but in my mind I think we'd 
better to because providing an uniformed view of data files, schema and other 
table metadata at the old timestamp `t3` matches the expectations from end 
users. 
   
   That's why I recommended to track the multiple versions of `RowKey` in 
iceberg table metadata. 


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

Reply via email to