amansinha100 commented on a change in pull request #1775: DRILL-7227: Fix
predicate check in DrillRelOptUtil.analyzeSimpleEquiJoin
URL: https://github.com/apache/drill/pull/1775#discussion_r280004824
##########
File path:
exec/java-exec/src/main/java/org/apache/drill/exec/planner/cost/DrillRelMdDistinctRowCount.java
##########
@@ -180,7 +180,7 @@ private Double getDistinctRowCountInternal(TableScan scan,
RelMetadataQuery mq,
}
}
s = Math.min(s, rowCount);
- if (!allCols) {
+ if (s == 1.0 && !allColsHaveNDV) {
Review comment:
Ah, yes..I somehow mistook that for selectivity. What about the check for
`s == 1.0` ? Even if that value is higher but at least 1 column does not have
NDV stats, I would think we want to return the 10% default.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services