On Mon, Mar 1, 2010 at 7:36 PM, Christopher Bottaro
<cjbott...@onespot.com> wrote:
> Hello,
>
> Is it possible to boost a document's score based on something like
> fq=site(com.google*).  In other words, I want to boost the score of
> documents who's "site" field starts with "com.google".
>
> I'm using the MoreLikeThisHandler.
>
> Thanks for the help,
> -- Christopher
>

Ok, I think I need to do this with BoostQParserPlugin and nested
queries, but I can't quite figure it out.

So this works...
q={!boost b=log(popularity)}(title:barack OR title:obama)

But instead of boosting by popularity, I want to boost by site:
q={!boost b=query({ !query q='site:*.yahoo.com' })}(title:barack OR title:obama)

This is the exception I get...
org.apache.lucene.queryParser.ParseException: Expected identifier at
pos 18 str='{!boost b=query({ !query q='site:*.yahoo.com'
})}(title:barack OR title:obama)'

But that doesn't work.  Any tips?  Thanks.

Reply via email to