-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: NEWBIE at Hibernate Search ... do I need a Filter?
PostPosted: Sat Jul 26, 2008 9:51 am 
Beginner
Beginner

Joined: Thu Aug 04, 2005 5:06 am
Posts: 31
Location: Bedford, UK
Hibernate Search version: 3.1.0b

Hello,

I've only just got Hibernate Search indexing a Product table for fullTextQuerying, just sweetly and speedily!
(and Luke looks pretty useful!)

But I have, on the same table, two unindexed fields that I would like to include in the query - countrycode and categoryid. (So I might want to select only products from the UK and/or products from a given category)

Is the answer a Filter?
(Bought the Hibernate Search in Action PDF but I need to run and walk now so to speak.)

Kind regards,

Mark Dathorne


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 29, 2008 8:56 pm 
Beginner
Beginner

Joined: Thu Aug 04, 2005 5:06 am
Posts: 31
Location: Bedford, UK
Ok, this is the scenario .. I have a Product table which is currently indexed
for Hibernate Search on the Product Name and Production Description fields.
But I want to also select on Category ID and/or Country Code.

Now reading through the Filter documentation (in Hibernate in Action), a filter is applied after the initial Lucene query.
I don't think this is what I want as I need to limit the search results ... so if I say only return the 1st 200 results and then apply a Country Code filter then I could end up with very little or no results!

This would indicate that I need to add the Country Code and Category Id to the lucene index and then somehow be able to include this is in the Hibernate Search query.

Now to try that ... any ideas/tips will be appreciated.

Mark Dathorne


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.