lidavidm commented on code in PR #718:
URL: https://github.com/apache/arrow-java/pull/718#discussion_r2051858753


##########
adapter/avro/src/main/java/org/apache/arrow/adapter/avro/AvroToArrowUtils.java:
##########
@@ -277,11 +333,17 @@ private static Consumer createConsumer(
         break;
       case BYTES:
         if (logicalType instanceof LogicalTypes.Decimal) {
-          arrowType = createDecimalArrowType((LogicalTypes.Decimal) 
logicalType);
+          LogicalTypes.Decimal decimalType = (LogicalTypes.Decimal) 
logicalType;
+          arrowType = createDecimalArrowType(decimalType, schema);
           fieldType =
               new FieldType(nullable, arrowType, /* dictionary= */ null, 
getMetaData(schema));
           vector = createVector(consumerVector, fieldType, name, allocator);
-          consumer = new 
AvroDecimalConsumer.BytesDecimalConsumer((DecimalVector) vector);
+          if (decimalType.getPrecision() <= 38) {

Review Comment:
   I think FIXED is okay to allow round-trip by default even if it's not 
technically as compact.



-- 
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: github-unsubscr...@arrow.apache.org

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

Reply via email to