lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From poojasreejith <po...@pivotsys.com>
Subject Re: Lucene searching class
Date Fri, 26 Oct 2007 04:33:55 GMT

Hi Steven,

    It really solved my problem. thanks a lot.

pooja


Steven Rowe wrote:
> 
> Hi Pooja,
> 
> poojasreejith wrote:
>>   I am using lucene2.2.0 for my application. I have a searcher.java
>> class.
>> The problem I am facing is, it is not supporting 
>> 
>> Query query = QueryParser.parse(q, "contents",new StandardAnalyzer()); 
>> it
>> shows error; the method parse in the type QueryParser is not applicable
>> for
>> the (String, String ,StandardAnalyzer).
> 
> Your code uses an obsolete static version of QueryParser.parse().  That
> method was deprecated in Lucene Java release 1.9.0, and was then removed
> in release 2.0.0.
> 
> You should instead instantiate a QueryParser instance, supplying the
> field name and analyzer to the constructor, and then call the
> parse(String query) instance method.
> 
> Here is the 2.2.0 javadoc for QueryParser:
> 
> <http://lucene.apache.org/java/2_2_0/api/org/apache/lucene/queryParser/QueryParser.html>
> 
> Steve
> 
> -- 
> 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
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Lucene-searching--class-tf4692438.html#a13420715
Sent from the Lucene - Java Users mailing list archive at Nabble.com.


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