mihaibudiu commented on code in PR #5390:
URL: https://github.com/apache/calcite/pull/5390#discussion_r4474091539
##########
core/src/main/java/org/apache/calcite/rel/metadata/RelMdSize.java:
##########
@@ -306,6 +306,12 @@ protected RelMdSize() {}
* is nullable.
*/
public @Nullable Double averageTypeValueSize(RelDataType type) {
+ if (type.getPrecision() == RelDataType.PRECISION_NOT_SPECIFIED
+ && SqlTypeUtil.inCharOrBinaryFamilies(type)) {
+ // Use a default estimate for unspecified precision, matching the
+ // cap used for large VARCHAR and VARBINARY types
+ return 100d;
Review Comment:
if it's matching maybe it should be a static final value someplace?
--
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]