Return-Path: Delivered-To: apmail-jakarta-lucene-dev-archive@www.apache.org Received: (qmail 40657 invoked from network); 9 Dec 2004 09:57:00 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 9 Dec 2004 09:57:00 -0000 Received: (qmail 86670 invoked by uid 500); 9 Dec 2004 09:56:54 -0000 Delivered-To: apmail-jakarta-lucene-dev-archive@jakarta.apache.org Received: (qmail 86649 invoked by uid 500); 9 Dec 2004 09:56:54 -0000 Mailing-List: contact lucene-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Lucene Developers List" Reply-To: "Lucene Developers List" Delivered-To: mailing list lucene-dev@jakarta.apache.org Received: (qmail 86633 invoked by uid 99); 9 Dec 2004 09:56:54 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=FORGED_RCVD_HELO X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from 99.227.181.62.in-addr.dgcsystems.net (HELO mail.pricerunner.com) (62.181.227.99) by apache.org (qpsmtpd/0.28) with SMTP; Thu, 09 Dec 2004 01:56:54 -0800 Received: (qmail 11785 invoked by uid 525); 9 Dec 2004 09:48:41 -0000 Received: from daniel.herlitz@pricerunner.com by drno.pricerunner.com by uid 522 with qmail-scanner-1.10 (. Clear:0. Processed in 0.155653 secs); 09 Dec 2004 09:48:41 -0000 Received: from unknown (HELO pricerunner.com) (unknown) by unknown with SMTP; 9 Dec 2004 09:48:41 -0000 Message-ID: <41B8214F.80507@pricerunner.com> Date: Thu, 09 Dec 2004 10:56:31 +0100 From: Daniel Herlitz User-Agent: Mozilla Thunderbird 0.5 (Windows/20040207) X-Accept-Language: en-us, en MIME-Version: 1.0 To: lucene-dev@jakarta.apache.org Subject: Count unique occurrences in hits Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N I have done a Lucene search and want to know the number of unique terms for a field (indexed) in the result. For example I have searched for a book title and want to know the number of authors (single terms) represented in the result. Is there any way of doing this without having to scan through all the hits? Thanks Daniel Herlitz --------------------------------------------------------------------- To unsubscribe, e-mail: lucene-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: lucene-dev-help@jakarta.apache.org