FAQ
if I search a keyword likes 'computer' in a shopping website.
the result may contains.
total:
(1000) products .
categories:
pc (500) products .
notebook (300) products .
server (200) products .

so how do get each categories 'amount.
I try to search many times on onec user search,
but it is so slow.
_________________________________________________________________
多个邮箱同步管理,live mail客户端万人抢用中
http://get.live.cn/product/mail.html

Search Discussions

  • Erik Hatcher at Jun 28, 2008 at 9:37 am

    On Jun 28, 2008, at 3:57 AM, lutan wrote:
    if I search a keyword likes 'computer' in a shopping website.
    the result may contains.
    total:
    (1000) products .
    categories:
    pc (500) products .
    notebook (300) products .
    server (200) products .

    so how do get each categories 'amount.
    I try to search many times on onec user search,
    but it is so slow
    This is a case where you are probably better off starting with Solr,
    which supports faceting natively.

    The main trick to making this fast is coming up with cached sets of
    each of the categories and intersecting each of those sets with the
    main result set and using the cardinality of the intersected sets for
    the counts. Again, Solr is what I'd recommend as a starting point for
    you.

    Erik


    ---------------------------------------------------------------------
    To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail: java-user-help@lucene.apache.org
  • Lutan at Jul 1, 2008 at 2:52 am
    Thanks for reply,but I am not know Solr well.
    Does Solr base on lucene core or hack lucene core
    to achieve the (categories amount)'s function ?
    Can I achieve the similar function using
    lucene core ?
    From: erik@ehatchersolutions.com> To: java-user@lucene.apache.org> Subject: Re: how to statistics categories amount> Date: Sat, 28 Jun 2008 05:36:12 -0400> > > On Jun 28, 2008, at 3:57 AM, lutan wrote:> > if I search a keyword likes 'computer' in a shopping website.> > the result may contains.> > total:> > (1000) products .> > categories:> > pc (500) products .> > notebook (300) products .> > server (200) products .> >> > so how do get each categories 'amount.> > I try to search many times on onec user search,> > but it is so slow> > This is a case where you are probably better off starting with Solr, > which supports faceting natively.> > The main trick to making this fast is coming up with cached sets of > each of the categories and intersecting each of those sets with the > main result set and using the cardinality of the intersected sets for > the counts. Again, Solr is what I'd recommend as a starting point for > you.> > Erik> > > --------------------------------------
    -------------------------------> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org> For additional commands, e-mail: java-user-help@lucene.apache.org>
    _________________________________________________________________
    多个邮箱同步管理,live mail客户端万人抢用中
    http://get.live.cn/product/mail.html
  • Lutan at Jul 3, 2008 at 6:05 am
    Anyone explain solr's function of facet ,thanks!
    How to using lucene to achieve. > From: erik@ehatchersolutions.com> To: java-user@lucene.apache.org> Subject: Re: how to statistics categories amount> Date: Sat, 28 Jun 2008 05:36:12 -0400> > > On Jun 28, 2008, at 3:57 AM, lutan wrote:> > if I search a keyword likes 'computer' in a shopping website.> > the result may contains.> > total:> > (1000) products .> > categories:> > pc (500) products .> > notebook (300) products .> > server (200) products .> >> > so how do get each categories 'amount.> > I try to search many times on onec user search,> > but it is so slow> > This is a case where you are probably better off starting with Solr, > which supports faceting natively.> > The main trick to making this fast is coming up with cached sets of > each of the categories and intersecting each of those sets with the > main result set and using the cardinality of the intersected sets for > the counts. Again, Solr is what I'd recommend as a starting point for > you.> > Erik> > > -----
    ----------------------------------------------------------------> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org> For additional commands, e-mail: java-user-help@lucene.apache.org>
    _________________________________________________________________
    用手机MSN聊天写邮件看空间,无限沟通,分享精彩!
    http://mobile.msn.com.cn/
  • Chris Hostetter at Jul 18, 2008 at 4:49 pm
    : Anyone explain solr's function of facet ,thanks!

    I gave talk a few years back which goes into some of hte details of
    doing faceting in Solr. that will give you a starting point, and then
    looking at the Solr "SimpleFacets" class can fill in the details.

    http://people.apache.org/~hossman/apachecon2006us/

    Note: the talk pre-dates the actual "SimpleFacets" functionality being
    added to Solr, so you won't see specific class names mentioned, and you
    will see some much simpler/crappier demo code of hte same principles.


    -Hoss


    ---------------------------------------------------------------------
    To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail: java-user-help@lucene.apache.org

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupjava-user @
categorieslucene
postedJun 28, '08 at 7:58a
activeJul 18, '08 at 4:49p
posts5
users3
websitelucene.apache.org

People

Translate

site design / logo © 2022 Grokbase