lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erick Erickson <>
Subject Re: How to specify dismax boost based on rating
Date Mon, 05 Dec 2011 13:54:30 GMT
Have you considered specifying a boost
function in your handler instead? See:


On Sun, Dec 4, 2011 at 12:43 AM, Zac Smith <> wrote:
> Hi,
> I think this is a pretty common requirement so hoping someone can easily point out the
> I have an average rating field defined in my schema that is a tdouble and can be anything
from 0 - 5 (including decimals). I am using dismax so I want to define a boost based on the
average rating. So the higher the number, the more it gets boosted. I am not sure how to specify
the boost in my request handler. The examples I have found show something like this:
>     <str name="bq">
>            rating:1^1.0 rating:2^2.0 rating:3^3.0 rating:4^4.0 rating:5^5.0
>        </str>
> But that seems to assume I would be using whole numbers. I need my rating to take into
account decimal values as well.
> Any pointers?

View raw message