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

Search doesn't return document via query

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 2.9.1, 2.9.4, 3.0.3
    • None
    • core/search
    • None
    • Doesn't depend on enviroment

    • New

    Description

      The query doesn't return document that contain all words from query in correct order.

      The issue might be within mechanism how do SpanQuerys actually match results (http://www.lucidimagination.com/blog/2009/07/18/the-spanquery/)

      Please refer for details below. The example text wasn't passed through snowball analyzer, however the issue exists after analyzing too

      Query:
      (intend within 3 of message) within 5 of message within 3 of addressed.

      Text within document:
      The contents of this e-mail message and
      any attachments are intended solely for the
      addressee(s) and may contain confidential
      and/or legally privileged information. If you
      are not the intended recipient of this message
      or if this message has been addressed to you
      in error, please immediately alert the sender
      by reply e-mail and then delete this message
      and any attachments

      Result query:

      SpanNearQuery spanNear = new SpanNearQuery(new SpanQuery[]

      { new SpanTermQuery(new Term(BODY, "intended")), new SpanTermQuery(new Term(BODY, "message"))}

      ,
      4,
      false);
      SpanNearQuery spanNear2 = new SpanNearQuery(new SpanQuery[]

      {spanNear, new SpanTermQuery(new Term(BODY, "message"))}

      , 5, false);
      SpanNearQuery spanNear3 = new SpanNearQuery(new SpanQuery[]

      {spanNear2, new SpanTermQuery(new Term(BODY, "addressed"))}

      , 3, false);

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              viruslviv Zenoviy Veres
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated: