lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Karl Wettin <karl.wet...@gmail.com>
Subject Re: Help needed ordering search results
Date Fri, 02 Oct 2009 04:08:21 GMT
Not quite sure what you ask for, but I think you want to use a span  
near query (for adding boost to phrases) in a disjunction max query  
(to define weights of the different fields).


     karl

1 okt 2009 kl. 02.40 skrev mitu2009:

>
> Hi,
>
> I've 3 records in Lucene index.
>
> Record 1 contains healthcare in title field. Record 2 contains  
> healthcare
> and insurance in description field but not together. Record 3 contains
> healthcare insurance in company name field.
>
> When a user searches for healthcare insurance,I want to show records  
> in the
> following order in search results...
>
> a.Record #3---because it contains both the words of the input  
> together(ie.as
> a phrase) b.Record #1 c.Record #2
>
> How do i achieve this in lucene?
>
> Thanks.
>
> -- 
> View this message in context: http://www.nabble.com/Help-needed-ordering-search-results-tp25691552p25691552.html
> Sent from the Lucene - Java Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> 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


Mime
View raw message