lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Erick Erickson" <erickerick...@gmail.com>
Subject Re: Match all documents with non empty field
Date Wed, 02 Jul 2008 21:47:29 GMT
You can certainly use a filter and MatchAllDocs. You can also
index a special value for the field in question (nothere) and
combine MatchAllDocs with a NOT field:nothere or some such.

Best
Erick

On Wed, Jul 2, 2008 at 5:25 PM, Patrick <patrek@gmail.com> wrote:

> Hi,
>
> Can't seem to wrap my head around how to go about it.
>
> I want to retrieve all documents where a certain field in not empty.
>
> What would be the best way to do it?
>
> Should I search with a MatchAllDocQuery and a Filter?
>
> Should I go through all terms in the field and create a TermQuery with it?
>
> Many thanks.
>
> Patrick
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
>

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