rdblue commented on code in PR #14101:
URL: https://github.com/apache/iceberg/pull/14101#discussion_r2830556733


##########
api/src/main/java/org/apache/iceberg/types/Conversions.java:
##########
@@ -120,6 +120,12 @@ public static ByteBuffer toByteBuffer(Type.TypeID typeId, 
Object value) {
         return (ByteBuffer) value;
       case DECIMAL:
         return ByteBuffer.wrap(((BigDecimal) 
value).unscaledValue().toByteArray());
+      case GEOMETRY:
+      case GEOGRAPHY:
+        // GEOMETRY and GEOGRAPHY values are represented as byte buffers. They 
are stored as WKB
+        // (Well-Known Binary) format in Iceberg, and geospatial bounding 
boxes are stored as
+        // serialized byte buffers. Return the byte buffer as is.

Review Comment:
   This should not be used for `BoundingBox`. This is for values, not for what 
you may compare values against.



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