Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-2987

QueryParser throwing null pointer exception if input is invalid

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 3.0.2
    • Fix Version/s: None
    • Component/s: core/queryparser
    • Labels:
    • Lucene Fields:
      New

      Description

      I was using org.apache.lucene.queryParser.QueryParser for parsing the input.
      My input:
      Input query string: "category: (4 or 6 or 8)"
      Analyzer: StandardAnalyzer
      QueryParser's parse() method is resulting in Null Pointer Exception.

      If i give input query string as "category: (4 OR 6 OR 8)" which is uppercase 'OR', it works fine and i get the desired results.
      I'm seeing the problem only with lower case 'or'

        Attachments

        1. LUCENE-2987.patch
          23 kB
          Joe Cabrera

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              ramesh.b.d Ramesh
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated: