Mailing List Archive

demo null path
Hi,

I've been testing the demo files (note that the java docs need updating)

So far the indexing on test files works ok.

Moving to HTML files:

I used the following command:

java -classpath %classpath% org.apache.lucene.IndexHTML -create .

adding ./powered.html
adding ./resources.html
Optimizing index...
1022 total milliseconds

..so far so good,

Now perform a search using command:

java -classpath %classpath% org.apache.lucene.SearchFiles

Query: Lucene
Searching for: lucene
2 total matching documents
0. null
1. null
Query:

OK so 2 total matching documents have been found, but why is
the document path null ?

Finally a note for future ideas:

would it be possible to obtain the original postion of the found
word in the file ?

Best regards to All

Mark
RE: demo null path [ In reply to ]
Well, that's because IndexHTML sets field url, and not field file.
But SearchFile tries to output the field file.
I think IndexHTML can only be used with the jhtml sample.
You may from the command line only the IndexFile, and SearchFile
together, or IndeHTML, and the jhtml/html sample.

I was having the same problems, you may try the jsp sample in
lucene-user for sample html indexing....
bye