Faceted count syntax (exclude zeros)...

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Faceted count syntax (exclude zeros)...

escher2k
I am trying to execute a faceted count on a field called "load_id" and want to exclude 0s. The URL below
doesn't seem to be excluding zeros.
http://localhost:12002/solr/select/?qt=dismax&q=Y&qf=show_all_flag&fl=load_id&facet=true&facet.limit=-1&facet.field=load_id&facet.mincount=1&rows=0

Result (relevant part of XML):
<lst name="facet_fields">
        <lst name="load_id">
           <int name="20070424150841">0</int>
           <int name="20070425145301">0</int>
           <int name="20070426145301">80</int>
           <int name="20070427145302">81</int>
           <int name="20070428145301">77</int>
           <int name="20070429145301">62</int>
           <int name="20070430145301">31061</int>
      </lst>
</lst>

Thanks.
Yao
Reply | Threaded
Open this post in threaded view
|

RE: Faceted count syntax (exclude zeros)...

Yao
There is an bug related to "facet.mincount" in incubating version.
http://www.mail-archive.com/solr-user@.../msg03269.html
-Yao

-----Original Message-----
From: escher2k [mailto:[hidden email]]
Sent: Tuesday, May 01, 2007 2:00 AM
To: [hidden email]
Subject: Faceted count syntax (exclude zeros)...


I am trying to execute a faceted count on a field called "load_id" and
want
to exclude 0s. The URL below
doesn't seem to be excluding zeros.
http://localhost:12002/solr/select/?qt=dismax&q=Y&qf=show_all_flag&fl=lo
ad_id&facet=true&facet.limit=-1&facet.field=load_id&facet.mincount=1&row
s=0

Result (relevant part of XML):
<lst name="facet_fields">
        <lst name="load_id">
           <int name="20070424150841">0</int>
           <int name="20070425145301">0</int>
           <int name="20070426145301">80</int>
           <int name="20070427145302">81</int>
           <int name="20070428145301">77</int>
           <int name="20070429145301">62</int>
           <int name="20070430145301">31061</int>
      </lst>
</lst>

Thanks.
--
View this message in context:
http://www.nabble.com/Faceted-count-syntax-%28exclude-zeros%29...-tf3673
535.html#a10264961
Sent from the Solr - User mailing list archive at Nabble.com.

Reply | Threaded
Open this post in threaded view
|

Re: Faceted count syntax (exclude zeros)...

Chris Hostetter-3
In reply to this post by escher2k

: to exclude 0s. The URL below
: doesn't seem to be excluding zeros.
: http://localhost:12002/solr/select/?qt=dismax&q=Y&qf=show_all_flag&fl=load_id&facet=true&facet.limit=-1&facet.field=load_id&facet.mincount=1&rows=0

which version of Solr are you using?  facet.mincount was added after Solr
1.1, but you can use "facet.zeros=false" to getthe desired results.



-Hoss