lucene-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Steven A Rowe" <sar...@syr.edu>
Subject RE: Query issue
Date Tue, 18 Dec 2007 13:23:15 GMT
Hi Jean-Claude,

The general@lucene.apache.org list is not subscribed to by very many people (guessing from
the very low traffic volume).  Questions like this will get much faster/better responses if
sent to java-user@l.a.o.

My guess is that you're using the StandardAnalyzer for querying, but not for indexing.  The
StandardAnalyzer includes a stop filter, which by default includes the word "is".  (StandardAnalyzer
also downcases words.)  Change the analyzer, or the stop list it uses, so that "is" is not
stopped.

Steve 


-----Original Message-----
From: Jean-Claude Antonio [mailto:jcantonio@arcetis.com]
Sent: Tue 12/18/2007 5:48 AM
To: general@lucene.apache.org
Subject: Query issue
 
|Hello, I have the following query problem.

With the below code,|| the query
"\\[prop\\]voila\\:type:RE" works well
but
"\\[prop\\]voila\\:type:IS" does not return any value (Hits size is 0)
The document was though added to the index (I can retrieve the IS 
document with some other query and the field was well popultated with 
"IS" value).
Any clue?


||
Document doc = new Document();
doc.add(new Field("[prop]voila:type", "IS", Field.Store.YES, 
Field.Index.TOKENIZED));
...
writer.addDocument(doc);

doc = new Document();
doc.add(new Field("[prop]voila:type", "RE", Field.Store.YES, 
Field.Index.TOKENIZED));
...
writer.addDocument(doc);


|


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