Thanks a lot for the clarification mike :-)
-- ** Kumaran R On Thu, Jun 2, 2016 at 2:38 AM, Michael McCandless < luc...@mikemccandless.com> wrote: > Well, each access may involve disk seeks (if the pages are not already hot > in the OS's IO cache). > > So if you do some doc values + some stored fields you're looking at > multiple seeks per docID you retrieve. > > Really you should only do this for a few hits, e.g. one page worth. > > Mike McCandless > > http://blog.mikemccandless.com > > On Wed, Jun 1, 2016 at 3:15 PM, Kumaran Ramasubramanian < > kums....@gmail.com> > wrote: > > > Hi All, > > > > > > In javadoc of every docvalue field > > < > > > https://lucene.apache.org/core/4_10_4/core/org/apache/lucene/document/SortedNumericDocValuesField.html > > >, > > there is line like > > > > > > > If you also need to store the value, you should add a separate > > StoredField > > > < > > > https://lucene.apache.org/core/4_10_4/core/org/apache/lucene/document/StoredField.html > > > > > > instance. > > > > > > > > > https://lucene.apache.org/core/4_10_4/core/org/apache/lucene/document/SortedNumericDocValuesField.html > > > > > > > > > > But, we are able to retrieve the value of SortedNumericDocValuesField > > using AtomicReader also > > > > for (AtomicReaderContext context : indexReader.leaves()) > > > { > > > AtomicReader atomicReader = context.reader(); > > > SortedNumericDocValues > > > sortedDocValues=DocValues.getSortedNumeric(atomicReader, "Numeric > > > _docvalue > > > _price"); > > > } > > > > > > So what is the difference actually? Is there any performance or time > taken > > issue in retrieving values of a docvalue field using atomicreader over > > StoredField? > > > > Please clarify me what am i missing? > > > > Thanks in advance > > > > > > -- > > > > Kumaran R > > >