lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Otis Gospodnetic <otis_gospodne...@yahoo.com>
Subject Re: Retrieving Field info from an index
Date Thu, 21 Mar 2002 17:30:28 GMT
In that case the place to look is org.apache.lucene.store package and
FSDirectory class.  Perhaps it treats those 2 fields differently.
I don't have time to look through it now, though.

Otis

--- Lex Lawrence <lex_lawrence@hotmail.com> wrote:
> Yes, I tried... and at first thought it was all working.  If you
> create a 
> document and then access its fields immediately, it gives you
> everything.  
> But if you store the document in an index, read it from the index,
> and then 
> try to access the fields, you don't get them all.  Of the five
> standard 
> Field types (Keyword, UnIndexed, Unstored, Text(String,String), 
> Text(String,Reader)) two are missing (Unstored and
> Text(String,Reader)).  
> See the attached test case, "FieldTest.java".
> 
> Thanks- Lex
> 
> 
> 
> >From: Otis Gospodnetic <otis_gospodnetic@yahoo.com>
> >Reply-To: "Lucene Users List" <lucene-user@jakarta.apache.org>
> >To: Lucene Users List <lucene-user@jakarta.apache.org>
> >Subject: Re: Retrieving Field info from an index
> >Date: Wed, 20 Mar 2002 22:19:18 -0800 (PST)
> >
> >Are you sure about this?
> >Try:
> ><your Document instance>.getField("<your field name>");
> >And also:
> ><your Document instance>.toString();
> >
> >Can you get/see your fields this way?
> >I took a look at the source and it looks like Document's add method
> >treats all Field types the same way, adds them to the same field
> list.
> >
> >Otis
> >
> >
> >--- Lex Lawrence <lex_lawrence@hotmail.com> wrote:
> > > Greetings-
> > >
> > > I am interested in getting information about the available Fields
> in
> > > an
> > > index.  Once I get hold of a Field object, it can provide
> everything
> > > I need,
> > > but I'm having trouble getting all of them.  I can use
> > > Document.fields() to
> > > get the "stored" Fields from an arbitrary document in the index.
> > > But... how
> > > can I get other Fields that may have been indexed and not stored?
> > >
> > > Thanks much!
> > > -Lex
> > >
> > >
> > > _________________________________________________________________
> > > Chat with friends online, try MSN Messenger:
> http://messenger.msn.com
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:
> > > <mailto:lucene-user-unsubscribe@jakarta.apache.org>
> > > For additional commands, e-mail:
> > > <mailto:lucene-user-help@jakarta.apache.org>
> > >
> >
> >
> >__________________________________________________
> >Do You Yahoo!?
> >Yahoo! Movies - coverage of the 74th Academy Awards®
> >http://movies.yahoo.com/
> >
> >--
> >To unsubscribe, e-mail:   
> ><mailto:lucene-user-unsubscribe@jakarta.apache.org>
> >For additional commands, e-mail: 
> ><mailto:lucene-user-help@jakarta.apache.org>
> >
> 
> 
> _________________________________________________________________
> Send and receive Hotmail on your mobile device: http://mobile.msn.com
> 

> ATTACHMENT part 2 application/octet-stream name=FieldTest.java
> --
> To unsubscribe, e-mail:  
> <mailto:lucene-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
<mailto:lucene-user-help@jakarta.apache.org>


__________________________________________________
Do You Yahoo!?
Yahoo! Movies - coverage of the 74th Academy Awards®
http://movies.yahoo.com/

--
To unsubscribe, e-mail:   <mailto:lucene-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:lucene-user-help@jakarta.apache.org>


Mime
View raw message