lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Steven Rowe <sar...@syr.edu>
Subject Re: Porter stemming problem
Date Fri, 22 Jun 2007 16:25:38 GMT
Hi Rob,

Robert Walpole wrote:
> At the moment I am attempting to do this as follows...
> 
> analyzer = new PorterStemAnalyzer();
> parser = new QueryParser("content", analyzer);
> Query query = parser.parse("keywords: relaxing");
> Hits hits = idxSearcher.search(query);
> 
> ...but this is not returning any matches.

Are you trying to look up "relaxing" in a field named "keywords"?  If
so, the intervening space defeats this - your code results in a search
for (stemmed versions of) "keywords:" or "relaxing" in the default
"content" field.

-- 
Steve Rowe
Center for Natural Language Processing
http://www.cnlp.org/tech/lucene.asp

---------------------------------------------------------------------
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