Return-Path: Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: (qmail 59828 invoked from network); 14 Apr 2006 00:18:32 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 14 Apr 2006 00:18:32 -0000 Received: (qmail 43096 invoked by uid 500); 14 Apr 2006 00:18:26 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 43072 invoked by uid 500); 14 Apr 2006 00:18:26 -0000 Mailing-List: contact java-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-user@lucene.apache.org Delivered-To: mailing list java-user@lucene.apache.org Received: (qmail 43061 invoked by uid 99); 14 Apr 2006 00:18:26 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 13 Apr 2006 17:18:26 -0700 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: local policy) Received: from [69.55.225.129] (HELO ehatchersolutions.com) (69.55.225.129) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 13 Apr 2006 17:18:25 -0700 Received: by ehatchersolutions.com (Postfix, from userid 504) id DB78533CAA5; Thu, 13 Apr 2006 20:18:04 -0400 (EDT) Received: from [172.16.1.101] (va-71-53-203-135.dhcp.sprint-hsd.net [71.53.203.135]) by ehatchersolutions.com (Postfix) with ESMTP id 3ED3033C108 for ; Thu, 13 Apr 2006 20:18:03 -0400 (EDT) Mime-Version: 1.0 (Apple Message framework v749.3) In-Reply-To: References: Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: Content-Transfer-Encoding: 7bit From: Erik Hatcher Subject: Re: Boosting Fields (in index) or Queries Date: Thu, 13 Apr 2006 20:17:59 -0400 To: java-user@lucene.apache.org X-Mailer: Apple Mail (2.749.3) X-Spam-Checker-Version: SpamAssassin 3.0.1 (2004-10-22) on javelina X-Spam-Level: X-Virus-Checked: Checked by ClamAV on apache.org X-Old-Spam-Status: No, score=-5.9 required=5.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.0.1 X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N The best recommendation is to have a look at the Explanation returned from IndexSearcher.explain() for a specific query and document to trace how things are being scored. Is it possible you're boosting all documents by the same amount? Erik On Apr 13, 2006, at 6:29 PM, Jeremy Hanna wrote: > I have a situation where I'm indexing database entries and have > fields such as: > > name > sku > model > category name > description > features > specifications > > I am trying to set a priority higher for the name, category name, > and description. > > I've tried setting the fields' boost values as I've indexed the db > and it seemed to have little or no result. > > When I tried to do the queries, I started using the > MultiFieldQueryParser but found that those don't have priority or > boost values you can set on any of the Fields at query time. Then > I tried to have separate query parsers - one for each field. That > way I could set a boost level for each of the queries created by > those query parsers. I joined them together with a BooleanQuery > and all of them set to BooleanQuery.Occur.SHOULD. I ended up > setting the features, specifications, and description to default to > Query.Operator.AND and that helped, but the boost value seems to do > nothing. > > I try to set the categoryParser's query boost to 4.0f, then 8.0f, > then 20.0f and have tried downgrading other queries, but the > results don't change at all in their order. > > I am using 1.9.1 and for my database I'm using hibernate to mysql 5 > and ArrayLists with the bag mapping in hibernate. > > Does anyone have any thoughts or suggestions? > > Thanks! > > Jeremy > > --------------------------------------------------------------------- > To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org > For additional commands, e-mail: java-user-help@lucene.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org For additional commands, e-mail: java-user-help@lucene.apache.org