lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Otis Gospodnetic <otis_gospodne...@yahoo.com>
Subject Re: boosting challenge
Date Mon, 29 Nov 2004 20:36:37 GMT
Try 4.0 instead of 4.  That may be correct syntax (don't have
QueryParser source to check), because the code takes boosts as float
type values.

Otis

--- Frank Morton <fmorton@base2inc.com> wrote:

> I have an index of restaurants with two fields. The "name" of the 
> restaurant and a "description".
> 
> I would like to search for the word "bob" in both fields, but if it 
> occurs in the "name", it would score higher. So, if "Bob Evans" is
> the 
> name of the restaurant, but other restaurants refer to "Bob" in the 
> description, the restaurant "Bob Evans" would score highest, but the 
> others would also match the query.
> 
> I thought you could boost the term with a query like:
> 
> name:bob^4 description:bob
> 
> and it would boost the word bob if found in the "name" property, but 
> this is not working for me. I get  the exact same results using the 
> above query and a simple "bob" query.
> 
> I am using lucene-1.4-final.jar.
> 
> I am using the PorterStemAnalyzer
> 
> Am I missing something. Lucene seems very capable,  otherwise.
> 
> Thanks.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: lucene-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: lucene-user-help@jakarta.apache.org
> 
> 


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


Mime
View raw message