lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Minh Kama Yie" <m...@nuix.com.au>
Subject Re: Is just "-foo" a valid query?
Date Wed, 11 Sep 2002 23:35:29 GMT
Dave,

Unfortunately using the "NOT" operator with a single term does not work as
explained in http://jakarta.apache.org/lucene/docs/queryparsersyntax.html

If you need to do this, create a global index that has the same value for
all documents and use the not operator in addition to this index when
searching.

Minh

----- Original Message -----
From: "Spencer, Dave" <dave@lumos.com>
To: "Lucene Users List" <lucene-user@jakarta.apache.org>
Sent: Thursday, September 12, 2002 9:28 AM
Subject: Is just "-foo" a valid query?



How do I find all the docs without single term e.g. "what docs do not
mention the word 'foo'".

The query "+foo" returns all docs w/ foo, and one would think that a
search on "-foo" would do the
job, however I get zero docs back when searching like this.
I'm using 1.2.
Is there something wrong w/ the query execution?

--
To unsubscribe, e-mail:
<mailto:lucene-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail:
<mailto:lucene-user-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:lucene-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:lucene-user-help@jakarta.apache.org>


Mime
View raw message