NobiGo commented on PR #3945:
URL: https://github.com/apache/calcite/pull/3945#issuecomment-2365069356

   @julianhyde I have made some improvements based on your suggestions.
   1. Refactor SqlTypeName#getDefaultScale to 
RelDataTypeSystem#getDefaultScale(SqlTypeName) and mark 
SqlTypeName#getDefaultScale as deprecated.
   2. Refactor SqlTypeName#getMinPrecision to 
RelDataTypeSystem#getMinPrecision(SqlTypeName) and mark 
SqlTypeName#getMinPrecision as deprecated.
   3. Refactor SqlTypeName#getMinScale to 
RelDataTypeSystem#getMinScale(SqlTypeName) and mark SqlTypeName#getMinScale as 
deprecated.
   4. Add Javadoc in RelDataTypeSystem#getMaxScale, 
RelDataTypeSystem#getMinScale, RelDataTypeSystem#getDefaultScale, and 
RelDataTypeSystem#getMinPrecision.
   5. Add getMinNumericScale in RelDataTypeSystem. getMinScale will use it when 
extracting decimal min scale(Same as getMaxPrecision(SqlTypeName) and 
getMaxNumericPrecision).
   6. I use RelDataType.SCALE_NOT_SPECIFIED as the default minimum scale for 
the type that doesn’t support scale. Not the Integer.MAX_VALUE. Because I think 
   RelDataType.SCALE_NOT_SPECIFIED is enough and makes the code logically 
simple.


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