On Wed, Jul 17, 2013 at 1:52 AM, VIGNESH S <vigneshkln...@gmail.com> wrote:
> Hi Mike,
>
> The Problem I mentioned is I used 3 Fields subject title, Content.
>
> I indexed Subject and Title like this..
>
> doc.add(new StringField(subject, mAccountId, Field.Store.YES));
>
> doc.add(new StringField(title, mSearchParam, Field.Store.YES));
>
> I indexed Content like this[as a TextField]
>
> FieldType offsetsType = new FieldType(TextField.TYPE_STORED);
>
> offsetsType.setIndexOptions(IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS);
> Document doc = new Document();
>  Field body = new Field(ContentIndex.KEY_TEXTCONTENT, "", offsetsType);
>  body.setStringValue(content);
>
> When I use Fields fields = MultiFields.getFields(mReader),I found only two
> fields coming subject and Title not the Content Field.

Then something is definitely wrong: indexing as TextField should
tokenize the string and make it into the index.

What analyzer are you using?

And when you say "I found only two fields coming subject and Title not
the Content Field", how are you getting those fields from the Fields
instance?

Can you make an isolated example showing the problem?

Mike McCandless

http://blog.mikemccandless.com

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org
For additional commands, e-mail: java-user-h...@lucene.apache.org

Reply via email to