Zoltan Haindrich created HIVE-18141:
---------------------------------------

             Summary: Fix StatsUtils.combineRange to combine intervals
                 Key: HIVE-18141
                 URL: https://issues.apache.org/jira/browse/HIVE-18141
             Project: Hive
          Issue Type: Sub-task
          Components: Statistics
            Reporter: Zoltan Haindrich
            Assignee: Zoltan Haindrich


the current [combinedRange 
implementation|https://github.com/apache/hive/blob/d9924ab3e285536f7e2cc15ecbea36a78c59c66d/ql/src/java/org/apache/hadoop/hive/ql/stats/StatsUtils.java#L1984]
 in its current form "combines" only ranges which contain eachother

but the comments suggests that the intention was to capture the case when the 2 
intervals are overlap; can be checked with the following testcase:

{code}
  @Test
  public void test11() {
    Range r1 = new Range(0, 1);
    Range r2 = new Range(1, 11);
    Range r3 = StatsUtils.combineRange(r1, r2);
    assertNotNull(r3);
  }
{code}




--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to