ZhangHuiGui commented on code in PR #40434:
URL: https://github.com/apache/arrow/pull/40434#discussion_r1525761873


##########
cpp/src/gandiva/decimal_type_util.cc:
##########
@@ -29,8 +29,11 @@ constexpr int32_t DecimalTypeUtil::kMinAdjustedScale;
   }
 
 // Implementation of decimal rules.
+// In addition to having a precision beyond 38, it is compatible with
+// **Redshift's decimal promotion rules** if enable use_redshift_rules.

Review Comment:
   > what does "In addition to having a precision beyond 38" mean here
   
   For decimal128, if the precision beyond 38, compute module's rules will 
report error with "Decimal precision out of range...".
   
https://github.com/apache/arrow/blob/54ff758a4570d9eeed9f6195dccdc21dcfe8d6d7/cpp/src/arrow/type.cc#L1471
   
   Gandiva adjust precision to 38 if beyond 38 through `MakeAdjustedType` 
function, i didn't change the rules here.
   Do you think we need to report error like compute module's rules if the 
precision beyond 38?



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

Reply via email to