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

ExtendedDismaxQParser (edismax) does not obey q.op for queries with operators

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 3.6.1, 4.0-BETA
    • None
    • query parsers
    • None

    Description

      For a query such as "cat dog OR (fox bat fish)" with &q.op=AND, the default query operator remains "OR" for the entire query. This is not documented behavior and rather surprising.

      This happens because edismax only simulates the default operator by forcing "mm" (minMatch) to 100% for the top-level BooleanQuery alone, but only if there are NO explicit operators present.

      One solution is for edismax to always set the default query operator when calling the classic Lucene query parser, or at least when q.op=AND.

      Attachments

        Activity

          People

            Unassigned Unassigned
            jkrupan Jack Krupansky
            Votes:
            4 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated: