Fokko commented on code in PR #12012:
URL: https://github.com/apache/iceberg/pull/12012#discussion_r1927674078


##########
core/src/test/java/org/apache/iceberg/TestSortOrder.java:
##########
@@ -342,6 +343,13 @@ public void testVariantUnsupported() {
         .hasMessage("Unsupported type for identity: variant");
   }
 
+  @Test
+  public void testUnknownSupported() {
+    Schema v3Schema = new Schema(Types.NestedField.optional(1, "u", 
Types.UnknownType.get()));
+
+    SortOrder.builderFor(v3Schema).withOrderId(10).asc("u").build();

Review Comment:
   I agree that this doesn't make sense, but as @HonahX pointed out here 
https://github.com/apache/iceberg/pull/12012#discussion_r1924520051, the 
`Unknown` type is a `PrimitiveType` and is accepted by the `IdentityTransform`. 
It doesn't make sense, but it is the same as sorting on a column that has many 
`null` values. I think we trust the user to make a wise decision and not to 
sort on an `UnknownType`, until it evolved in an actual type.



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

Reply via email to