lucene-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wolfgang T├Ąger <>
Subject Re: Article keyword counters
Date Wed, 26 Jul 2006 09:33:58 GMT
Hi Laci,

You may just search for key 2 and then use a FilteredQuery.




"laszlo sera" <> 
25-07-2006 17:38
Please respond to


Article keyword counters

Hi all,

I need some help from the Lucene experts because I coulnd't find the
best solution for a problem...

The problem: we have article entities which can have multiple keywords:

- article #1: keyword #1, keyword#2, keyword#3
- article #2: keyword#2, keyword#3
- article #3: keyword#3
- article #4: keyword#4

I need to create a method to produce a list like this for keyword #2:

- keyword#1 (1)
- keyword#2 (2)
- keyword#3 (1)
- keyword#2 (0)

This list shows counters of keywords and a counter means that how many
article matches with the given keyword in the given scope (in this
example: keyword#2). So, there's one article which has keyword#1 and

What's the best way to produce the counters?


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message