thnks erik
thnks for your reply...
with regards,
Erik Hatcher <[EMAIL PROTECTED]> wrote:
On Oct 5, 2005, at 4:17 AM, shadab khan wrote:
> hi all,
> while indexing for a document, one field i am using is "contents".
>
> doc.add(Field.Text("contents", reader));
>
> the "contents" field is not being stored in index(only being
> tokenize and indexing. Now my problem is to find the position for a
> word from this field(i.e. contents). if you have a solution for
> this plzz send it to me asap.
One solution is to store it. :) Field.Text(String,Reader) does not
store though, only Field.Text(String,String). So you will need to
load it as a String first to do that. An alternative is to grab the
contents from its original location when you need the positions and
re-run the Analyzer on the text to get the Tokens with position
information. There is also some enhancements in the trunk
(unreleased) version of Lucene you may try to store offset and
position information in the index.
Erik
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------
Yahoo! India Matrimony: Find your partner now.