lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bourne71 <>
Subject Generating Query
Date Wed, 12 Aug 2009 09:09:09 GMT


I am trying to build a query that looks like the following:
url:(+news +politics)^1.5 content:(+news +politics)^2.0

But I can't seems to find any reference to it. I try hardcoding it like the
BooleanQuery query = new BooleanQuery();
query.add(new TermQuery(new Term(field, "+news +politics")),

But with this, the query doesn't seems to provide any response or effect. By
right its suppose to boost the field of the page that contain both of the
word in it.

Can anyone advise me on how to create this type of query? Thanks
View this message in context:
Sent from the Lucene - Java Users mailing list archive at

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

View raw message