lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erik Hatcher <>
Subject Re: search exception in servlet!Please help me
Date Wed, 04 Aug 2004 10:23:49 GMT
My deepest apologies - I totally misspoke with my post yesterday.  
Chris, and the others, are correct - I wasn't thinking clearly and was 
confusing IndexReader.document() with Hits.doc().

So, as far as the exception goes - perhaps your servlet does not have 
access to the index because of permissions.  Maybe you're using a 
different version of Lucene between the command-line and your web 


On Aug 4, 2004, at 3:14 AM, Christiaan Fluit wrote:

> Erik Hatcher wrote:
>> Where did you get 'i'?   Keep in mind that using Hits.doc(n) intends 
>> 'n' to be a document *id*, not the iteration through the Hits 
>> collection.  This is a very common mistake, and I'm guessing one 
>> you've made here.
> I believe the Javadoc (as well as my own experience) tells otherwise:
> "public final Document doc(int n) throws IOException
>     Returns the stored fields of the nth document in this set."
> Regards,
> Chris
> --
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

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

View raw message