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

Reply via email to