I want to parse a simple query using lucene (3.0.3):

title:(+return +"pink panther")

Just like in the documentation example.

The expected result is:

+title:return +title:"pink panther"

But instead i get:

+title:return +title:"itle return pink panther"

The code is very simple (c#):

Query query = 
    new QueryParser(
        Lucene.Net.Util.Version.LUCENE_30, 
        "content", 
        new Lucene.Net.Analysis.Standard.StandardAnalyzer(Lucene.Net.Util.Version.LUCENE_30))
    .Parse("title:(+return +\"pink panther\")");
有帮助吗?

解决方案 2

Sorry for the trouble, the issue was a custom-modified Lucene.Net assembly...

其他提示

I'm unable to reproduce this. Does this still occur for you?

I'm thinking that it may be some display artifacts from the output window. Is this from the Immediate Window, the Watch Window or a call to Console.WriteLine?

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top