So i want to filter and sort on a field. Can i only use doc_values or
should i also index the field for filtering ? (meaning is doc_values only
for sorting/faceting)
Since doc_values accepts 'long' data types, does it also accept 'dates'
since they are stored as 'long' ?
If a document has expired but hasn't yet been deleted, is it returned when
searching ?
So i want to filter and sort on a field. Can i only use doc_values or
should i also index the field for filtering ? (meaning is doc_values only
for sorting/faceting)
Filtering will work without indexing the field if the filter that you would
like to use has a 'field_data' execution mode. For example, the range
filter[1] is able to use field data to execute the filter.
However, please note that the field_data execution mode of filters is very different from the index execution mode and may be much slower if
your filter matches few documents (and vice-versa, it may behave better if
your filter matches most documents).
Since doc_values accepts 'long' data types, does it also accept 'dates'
since they are stored as 'long' ?
Indeed, dates support doc values.
If a document has expired but hasn't yet been deleted, is it returned when
searching ?
Yes, documents which have expired but are not deleted yet will be returned.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.