lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From liat oren <>
Subject MultiSegmentReader problems - current is null
Date Sun, 28 Jun 2009 12:39:49 GMT

I have an index that is a multi-segment index (how come it is created this

When I try to get the freq of a term at the following way:
   TermDocs tDocs = this.indexReader.termDocs(term);
   tf = tDocs.freq();
the greq method :
  public int freq()
   return current.freq();
is in MultiSegmentReader.

The current is null, so I get an exception.

Should I initialize current?
How can I avoid this problem?
How can I avoid having a multi-segment index?

Many thanks,

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message