lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mike Richmond" <>
Subject Lucene query question
Date Wed, 10 May 2006 02:18:29 GMT
I am new to Lucene, but the behavior that I am seeing does not seem to
make sense to me.  I am using the latest version of Lucene (1.9.1) and
executing the following code below which creates an index with a
single document and only one field (named "test") with a value of

If I use Luke to search through this newly created index using a query such as:
"" I do not get any matches.  However, if
using Luke I browse to the document and click the "Reconstruct & Edit"
button then without making any changes save the document I can then
rerun the same query and it will find the document!

Is this normal?  The only thing I can think of is that the index was
created with Lucene 1.9.1 and is being searched using Luke (which was
probably written using an older version of Lucene).  Any help would be
greatly appreciated.

Thanks in advance,


-------------------CODE SNIPPET BELOW-----------------

IndexWriter iw = new IndexWriter("index", new StandardAnalyzer(), true);
Document d = new Document();

d.add( new Field("test", "", Field.Store.YES,

iw.addDocument( d );


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message