lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Warren" <>
Subject Same query different results?
Date Thu, 25 Oct 2007 04:33:06 GMT
I have two two similar query's that give me the same results when I run them
in Luke, but when I run them in my app, one of the querys gives me the
correct results and the other query gives me no results. I am using
StandardAnalyzer in both Luke and my app.

Query 1:
This query works correctly in my app and Luke

+(upc:almonds description:almonds content:almonds) +dept:bulk +zone:1

Query 2:
This query works correctly in Luke but returns no results in my app

+(upc:almonds description:almonds content:almonds) +dept:"Bulk" +zone:1

My app code:

Directory dir = FSDirectory.getDirectory(indexDir);
IndexSearcher searcher = new IndexSearcher(dir);
Hits hits =;

The only difference is that the term "bulk" is quoted in one query and not
quoted in the other. Shouldn't both of these querys get the same results
when useing StandardAnalyzer? Isn't one term quoted the same as one term

What am I missing?



To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message