liyafan82 opened a new pull request #2146:
URL: https://github.com/apache/calcite/pull/2146


   1. For {{RelMdColumnUniqueness#areColumnsUnique(RelSubset, RelMetadataQuery,
   ImmutableBitSet, boolean)}}, we can return early as we encounter the first 
null.
   
   2. For {{RelMdDistinctRowCount#getDistinctRowCount(Values, RelMetadataQuery,
   ImmutableBitSet, RexNode)}}, we can get the distinct row count accurately, 
instead of guessing that half of the elements are distinct. 
   
   3. In class RelMdUtil, areColumnsDefinitelyUnique and 
areColumnsDefinitelyUniqueWhenNullsFiltered have identical behaviors, so we 
should use the formmer, which is more efficient. 


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


Reply via email to