lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adrien Grand <>
Subject Re: Sorting, Range Query, faceting - NumericDocValuesField Vs LongField
Date Thu, 22 Dec 2016 17:57:52 GMT
Le jeu. 22 déc. 2016 à 18:50, Kumaran Ramasubramanian <>
a écrit :

> I want to provide sorting, range search and faceting in numeric fields.
> AFAIK, Purpose of different numeric field types are,
> NumericDocValuesField supports sorting and faceting
> LongField/IntField supports range query and sorting

LongField/IntField only support querying, NumericDocValuesField is the one
that supports sorting.

Also note that as of 6.0 LongField and IntField have been replaced with
LongPoint and IntPoint.

> 1. Should i duplicate one field in above mentioned types to achieve all the
> three features in numeric?

Yes. By the way it is perfectly fine to use the same field name for the
point field and the doc values field.

> 2. If i am ready to sacrifice faceting, is it advisable to use LongField
> for sorting and range query?

Like said above you need doc values for sorting.

> 3. During sorting, Will NumericDocValuesField( column stride storage)
> perform better than LongField(trie structure)? If so , should i duplicate
> field in both 1 and 2 cases?

Same note here.


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