lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Hostetter <>
Subject Re: Searching for empty fields
Date Wed, 07 May 2008 15:35:46 GMT

: (*:* AND -color:[* TO *])

the *:* shouldn't be neccessary in Solr, fq=-color:[* TO *] should work just fine.

: > One of the fields in my database is color. It can either contain a value
: > (blue, red etc) or be blank. When I perform a search with facet counts on, I
: > get a count for "_empty_".

For the record, nothing in Solr's SimpleFacet code will produce the string 
"_empty_" ... if facet.missing=true then a count of all docs with no value 
will be included, but it doesn't have a label (ala hte example on the 

 <lst name="facet_fields">
  <lst name="cat">
        <int name="music">1</int>
        <int name="connector">2</int>
        <int name="electronics">3</int>
        <int>1</int>   <!-- this is the facet.missing count -->


View raw message