lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Yonik Seeley" <>
Subject Re: Sort problematics
Date Thu, 18 May 2006 21:01:56 GMT
On 5/18/06, Marcus Falck <> wrote:

> If i use lucene default implementation of the TermScorer and search for
> "you" OR "her"
> The term scorer will give higher score on documents containing both terms. This is a
problem (in our application) since in this case want the same score on documents as long as
they contain 1 of the terms

If this is your problem, it has nothing to do with "sorting" (using
Lucene terminology) but scoring.  There are numbers of ways:

1) Change Similarity.coord()  (read the JavaDoc for Similarity)
2) DisjunctionMaxQuery
3) query "you" and "her" separately and use the union of the results

-Yonik Solr, the open-source Lucene search server

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

View raw message