Repository: phoenix
Updated Branches:
  refs/heads/4.8-HBase-1.2 e55a27901 -> ffa6476cb


PHOENIX-3608 KeyRange interset should return EMPTY_RANGE when one of it is 
NULL_RANGE(Rajeshbabu)


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

Branch: refs/heads/4.8-HBase-1.2
Commit: ffa6476cb029d4cd7b1a82675c996c3821266158
Parents: e55a279
Author: Rajeshbabu Chintaguntla <[email protected]>
Authored: Fri Jan 20 19:08:08 2017 +0530
Committer: Rajeshbabu Chintaguntla <[email protected]>
Committed: Fri Jan 20 19:08:08 2017 +0530

----------------------------------------------------------------------
 .../src/main/java/org/apache/phoenix/query/KeyRange.java        | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/phoenix/blob/ffa6476c/phoenix-core/src/main/java/org/apache/phoenix/query/KeyRange.java
----------------------------------------------------------------------
diff --git a/phoenix-core/src/main/java/org/apache/phoenix/query/KeyRange.java 
b/phoenix-core/src/main/java/org/apache/phoenix/query/KeyRange.java
index f4bf793..babce9d 100644
--- a/phoenix-core/src/main/java/org/apache/phoenix/query/KeyRange.java
+++ b/phoenix-core/src/main/java/org/apache/phoenix/query/KeyRange.java
@@ -356,10 +356,9 @@ public class KeyRange implements Writable {
         boolean newUpperInclusive;
         // Special case for null, is it is never included another range
         // except for null itself.
-        if (this == IS_NULL_RANGE) {
-            if (range == IS_NULL_RANGE) {
+        if (this == IS_NULL_RANGE && range == IS_NULL_RANGE) {
                 return IS_NULL_RANGE;
-            }
+        } else if(this == IS_NULL_RANGE || range == IS_NULL_RANGE) {
             return EMPTY_RANGE;
         }
         if (lowerUnbound()) {

Reply via email to