wgtmac commented on a change in pull request #992:
URL: https://github.com/apache/orc/pull/992#discussion_r779988605
##########
File path: java/core/src/java/org/apache/orc/impl/RecordReaderImpl.java
##########
@@ -706,13 +749,19 @@ static TruthValue evaluatePredicateRange(PredicateLeaf
predicate,
ValueRange range,
BloomFilter bloomFilter,
boolean useUTCTimestamp) {
+ if (!range.valid()) {
+ return TruthValue.YES_NO_NULL;
Review comment:
I have checked that the C++ implementation has already handled this case.
##########
File path: java/core/src/java/org/apache/orc/impl/RecordReaderImpl.java
##########
@@ -462,8 +482,31 @@ public long getNext() {
this(predicate, null, null, hasNulls, false, false);
}
+ ValueRange(PredicateLeaf predicate, boolean hasNulls, boolean hasValue,
boolean comparable) {
+ this(predicate, null, null, hasNulls, false, false, hasValue,
comparable);
+ }
+
boolean hasValues() {
- return lower != null;
+ return hasValue;
+ }
+
+ /**
+ * This method is used separately when the hasValue is true
+ * Whether min or max is provided for comparison
+ * @return is it comparable
+ */
+ boolean comparable() {
+ return comparable;
Review comment:
According to the comment above, should we check hasValue just in case
any misuse.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]