Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-14859

[* TO *] queries on DateRange fields miss results

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 8.5
    • 8.6.3, 8.7, 9.0
    • query parsers
    • None

    Description

      "exists" queries ([* TO *]) on DateRange fields return 0 results regardless of docs in the index with values in that field.

      The issue appears to be that the query is converted into a NormsFieldExistsQuery, even though DateRangeField uses omitNorms=true by default. Probably introduced by SOLR-11746's changes to these optimizable range queries.

      I've attached a script to reproduce the issue (tested on Solr 8.6.2) and screenshots showing showing schema and query-parsing info for the reproduction.

      Attachments

        1. SOLR-14859.patch
          2 kB
          Chris M. Hostetter
        2. SOLR-14859.patch
          6 kB
          Jason Gerlowski
        3. SOLR-14859.patch
          7 kB
          Jason Gerlowski
        4. SOLR-14859.patch
          9 kB
          Jason Gerlowski
        5. SOLR-14859.patch
          7 kB
          Jason Gerlowski
        6. SOLR-14859.patch
          13 kB
          Jason Gerlowski
        7. schema.png
          24 kB
          Jason Gerlowski
        8. reproduce.sh
          0.9 kB
          Jason Gerlowski
        9. query-debug.png
          42 kB
          Jason Gerlowski

        Issue Links

          Activity

            People

              gerlowskija Jason Gerlowski
              gerlowskija Jason Gerlowski
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: