Github user wzhfy commented on a diff in the pull request:

    https://github.com/apache/spark/pull/19783#discussion_r153973474
  
    --- Diff: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/logical/statsEstimation/FilterEstimation.scala
 ---
    @@ -513,10 +560,9 @@ case class FilterEstimation(plan: Filter) extends 
Logging {
     
             op match {
               case _: GreaterThan | _: GreaterThanOrEqual =>
    -            // If new ndv is 1, then new max must be equal to new min.
    -            newMin = if (newNdv == 1) newMax else newValue
    +            newMin = newValue
               case _: LessThan | _: LessThanOrEqual =>
    -            newMax = if (newNdv == 1) newMin else newValue
    +            newMax = newValue
    --- End diff --
    
    why change these two line?


---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to