lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Muir <rcm...@gmail.com>
Subject Re: Search returning documents matching a NOT range
Date Wed, 10 Nov 2010 12:25:24 GMT
On Wed, Nov 10, 2010 at 7:00 AM, Robert Muir <rcmuir@gmail.com> wrote:
> On Mon, Nov 8, 2010 at 6:45 AM, Ian Lea <ian.lea@gmail.com> wrote:
>> This does seem extremely odd.  David sent me a copy of his index and
>> I've played around with it and also written a self-contained RAM index
>> program, below, that shows the same problem, namely that if the second
>> index has 1000+ docs the one and only doc in the first index is
>> incorrectly matched if the search is done with a MultiSearcher.  In
>> answer to Uwe's question, it works correctly if use a single
>> IndexSearcher on top of a MultiReader.
>

I played with your testcase, and it seems the rewrite() implementation
is causing the strangeness you see.
for your query: author:aaa -pubdate:[aaa TO bbb], here are the rewritten forms:

MultiReader case: +author:aaa -ConstantScore(pubdate:[aaa TO bbb])
MultiSearcher case: (+author:aaa -()) (+author:aaa
-ConstantScore(pubdate:[aaa TO bbb]))

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message