ILuffZhe commented on code in PR #4432:
URL: https://github.com/apache/calcite/pull/4432#discussion_r2160977978


##########
core/src/main/java/org/apache/calcite/sql/validate/SqlValidatorImpl.java:
##########
@@ -3459,7 +3459,7 @@ private void registerOperandSubQueries(
       final BigDecimal noTrailingZeros = bd.stripTrailingZeros();
       // If we don't strip trailing zeros we may reject values such as 
1.000....0.
 
-      final int maxPrecision = typeSystem.getMaxNumericPrecision();
+      final int maxPrecision = typeSystem.getMaxPrecision(SqlTypeName.DECIMAL);

Review Comment:
   You can take a look at UBIGINT in SqlTypeName, which belongs to DECIMAL type 
family.
   I also add some tests to make it more readable.



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