You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by Karl Koch <Th...@gmx.net> on 2005/02/15 17:45:08 UTC

Fieldinformation from Index

Hello,

I have two questions which might be easy to answer from a Lucene expert:

1) I need to know which fields a collection of Documents has (given the fact
that not all docuemnts do necessaryly use all fields). This Documents are
all stored in one index. Is there a way (with Lucene 1.2 or 1.3) to find out
without going though each document and retrieving it?

2) I need to know which Analyzer was used to index a field. One important
rule, as we all know, is to use the same analyzer for indexing and searching
a field. Is this information stored in the index or in full responsibilty of
the application developer?

Karl

-- 
DSL Komplett von GMX +++ Superg�nstig und stressfrei einsteigen!
AKTION "Kein Einrichtungspreis" nutzen: http://www.gmx.net/de/go/dsl

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


Re: Fieldinformation from Index

Posted by Erik Hatcher <er...@ehatchersolutions.com>.
On Feb 15, 2005, at 11:45 AM, Karl Koch wrote:
> 2) I need to know which Analyzer was used to index a field. One 
> important
> rule, as we all know, is to use the same analyzer for indexing and 
> searching
> a field. Is this information stored in the index or in full 
> responsibilty of
> the application developer?

The analyzer is not stored in the index, nor its name.  I believe this 
was discussed in the past, though.

It's not a rule that the same analyzer be used for both indexing and 
searching, and there are cases where it makes sense to use different 
ones.  The analyzers must be compatible though.

	Erik


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