Sorting and faceting use docValues for the fastest implementation, range queries use the index for the fastest implementation.
In general I would advise to have everything (indexed, docValues, stored) turned on unless you have an explicit reason not to. - Houston On Tue, Jun 27, 2023 at 9:57 AM Szűcs Roland <[email protected]> wrote: > I planned to use only docValues="true" for an intPointField. is It not > enough for efficient faceting, range queries and sorting? Do I need > indexed="true" in addition to the docsValues? > > Roland > > Ishan Chattopadhyaya <[email protected]> ezt írta (időpont: 2023. > jún. 27., K, 14:43): > > > If you disable docValues, then you would need stored=true to return the > > values along with the search results. > > > > On Tue, 27 Jun, 2023, 6:06 pm Jan Høydahl, <[email protected]> > wrote: > > > > > You need indexed="true" to enable the dimensional index structure > > > supporting range filters. If you do not ever need sorting on the field > I > > > suppose you could disable docValues. > > > > > > Jan > > > > > > > 27. jun. 2023 kl. 11:51 skrev Szűcs Roland < > > [email protected] > > > >: > > > > > > > > Hi Solr developers, > > > > > > > > I would like to have a price field in Solr with integer type. I need > to > > > > store it. In addition to show it in the search result, the only role > of > > > > this field is to use it as a range filter. > > > > > > > > My question is what fieldType should I use as a best practice. I have > > > read > > > > that: > > > > "For general numeric needs, consider using one of the IntPointField, > > > > LongPointField, FloatPointField, or DoublePointField classes, > depending > > > on > > > > the specific values you expect. These "Dimensional Point" based > numeric > > > > classes use specially encoded data structures to support efficient > > range > > > > queries regardless of the size of the ranges used. Enable DocValues > > > > < > > https://solr.apache.org/guide/solr/latest/indexing-guide/docvalues.html> > > > on > > > > these fields as needed for sorting and/or faceting." > > > > Based on this, am I correct that I should use InpointField with > > > > indexed="false" stored="true" docValues="true" for my use case? > > > > > > > > Thanks in advance, > > > > Roland > > > > > > > > P.S.: It is not clear at all what does "Dimensional Point" means for > a > > > > scalar value > > > > > > > > >
