kylin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nju_y...@apache.org
Subject [03/50] kylin git commit: KYLIN-1420 Query returns empty result on partition column's boundary condition
Date Mon, 18 Apr 2016 06:34:45 GMT
KYLIN-1420 Query returns empty result on partition column's boundary condition

Project: http://git-wip-us.apache.org/repos/asf/kylin/repo
Commit: http://git-wip-us.apache.org/repos/asf/kylin/commit/8880740d
Tree: http://git-wip-us.apache.org/repos/asf/kylin/tree/8880740d
Diff: http://git-wip-us.apache.org/repos/asf/kylin/diff/8880740d

Branch: refs/heads/1.4-rc
Commit: 8880740d598802595edb1ed89f8e0d75b3a38d6a
Parents: ebce31e
Author: shaofengshi <shaofengshi@apache.org>
Authored: Mon Feb 15 15:52:15 2016 +0800
Committer: shaofengshi <shaofengshi@apache.org>
Committed: Mon Feb 15 15:52:15 2016 +0800

----------------------------------------------------------------------
 .../main/java/org/apache/kylin/gridtable/GTScanRangePlanner.java | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kylin/blob/8880740d/core-cube/src/main/java/org/apache/kylin/gridtable/GTScanRangePlanner.java
----------------------------------------------------------------------
diff --git a/core-cube/src/main/java/org/apache/kylin/gridtable/GTScanRangePlanner.java b/core-cube/src/main/java/org/apache/kylin/gridtable/GTScanRangePlanner.java
index 837abf0..7551e49 100644
--- a/core-cube/src/main/java/org/apache/kylin/gridtable/GTScanRangePlanner.java
+++ b/core-cube/src/main/java/org/apache/kylin/gridtable/GTScanRangePlanner.java
@@ -126,8 +126,8 @@ public class GTScanRangePlanner {
         for (ColumnRange range : andDimRanges) {
             if (partitionColRef != null && range.column.equals(partitionColRef))
{
                 if (rangeStartEndComparator.comparator.compare(segmentStartAndEnd.getFirst(),
range.end) <= 0 //
-                        && rangeStartEndComparator.comparator.compare(range.begin,
segmentStartAndEnd.getSecond()) < 0) {
-                    //segment range is [Closed,Open)
+                        && rangeStartEndComparator.comparator.compare(range.begin,
segmentStartAndEnd.getSecond()) <= 0) {
+                    //segment range is [Closed,Open), but segmentStartAndEnd.getSecond()
might be rounded, so use <=. 
                 } else {
                     logger.debug("Pre-check partition col filter failed, partitionColRef
{}, segment start {}, segment end {}, range begin {}, range end {}",//
                             new Object[] { partitionColRef, makeReadable(segmentStartAndEnd.getFirst()),
makeReadable(segmentStartAndEnd.getSecond()), makeReadable(range.begin), makeReadable(range.end)
});


Mime
View raw message