You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by qaz zaq <fo...@yahoo.com> on 2006/12/14 16:19:48 UTC

Duplicates removal in search results

How can i remove the duplicates records in the search results. i.e., I have multiple results with the same title in 'title' field, and I want to only 1 record per title, how can I achieve that? thanks!!

 
---------------------------------
Everyone is raving about the all-new Yahoo! Mail beta.

Re: Duplicates removal in search results

Posted by Erick Erickson <er...@gmail.com>.
you need to search for all documents with the title you care about, decide
which one to keep and remove all the others.

You'll probably need a TermDocs/TermEnum to go through all the items in your
index to create the list of documents to remove.

Erick

On 12/14/06, qaz zaq <fo...@yahoo.com> wrote:
>
> How can i remove the duplicates records in the search results. i.e., I
> have multiple results with the same title in 'title' field, and I want to
> only 1 record per title, how can I achieve that? thanks!!
>
>
> ---------------------------------
> Everyone is raving about the all-new Yahoo! Mail beta.
>