Skip to content

Commit

Permalink
Ensure that the points are intersecting for doc_values
Browse files Browse the repository at this point in the history
Signed-off-by: Harsha Vamsi Kalluri <[email protected]>
  • Loading branch information
harshavamsi committed Jan 22, 2024
1 parent 923e442 commit 8c94003
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@

import org.apache.lucene.document.LongPoint;
import org.apache.lucene.document.SortedNumericDocValuesField;
import org.apache.lucene.document.SortedSetDocValuesField;
import org.apache.lucene.document.StoredField;
import org.apache.lucene.index.IndexReader;
import org.apache.lucene.index.PointValues;
Expand Down Expand Up @@ -568,6 +569,9 @@ public Relation isFieldWithinQuery(
DateMathParser dateParser,
QueryRewriteContext context
) throws IOException {
if (isSearchable() == false && hasDocValues()) {
return Relation.INTERSECTS;
}
if (dateParser == null) {
dateParser = this.dateMathParser;
}
Expand Down

0 comments on commit 8c94003

Please sign in to comment.