If I understand you properly, I do it using a Filter Query:

fq=NOT(field:EMPTY)

Hope that helps -

Sas


-----Original Message-----
From: Valentina Cavazza [mailto:valent...@step-net.it] 
Sent: Friday, July 15, 2016 10:17 AM
To: solr-user@lucene.apache.org
Subject: search documents that have a specific field populated

Hi,
I need to search documents that have a specific field populated, so I want to 
display all the documents that have the field not empty.
This field in schema is set multivalued=true, indexed=true, stored=true, 
default=EMPTY.
This field type is solr.TextField class, use StandardTokenizerFactory 
tokenizer, ICUFoldingFilterFactory filter, LowerCaseFilterFactory filter and 
GreekStemFilterFactory filter in index and query analizer.
I already tried queries like this:
q=field:*
q=+field:*
q=+field:[* TO *]
q=+field:['' TO *]
q=+field:["" TO *]
q=+field:[' ' TO *]
q=+field:' '
q=-field:EMPTY

but nothing found.
Someone know how to do that?
Thanks

Valentina

Reply via email to