Re: Docvalue v.s. invert index

2018-08-17 Thread Mikhail Khludnev
org.apache.lucene.search.IndexOrDocValuesQuery might be also relevant. On Mon, Aug 13, 2018 at 9:02 AM Zahra Aminolroaya wrote: > Thanks Erick, Shawn and Tomoko for complete answers. > > If I set both docvalue and indexed "true" in a field, will Solr understand > to use which technique for

Re: Docvalue v.s. invert index

2018-08-13 Thread Shawn Heisey
On 8/13/2018 12:02 AM, Zahra Aminolroaya wrote: Thanks Erick, Shawn and Tomoko for complete answers. If I set both docvalue and indexed "true" in a field, will Solr understand to use which technique for faceting or searching? Or Is there any way to inform Solr to use which technique? Solr

Re: Docvalue v.s. invert index

2018-08-13 Thread Erick Erickson
"My expectation is that scanning Doc Values might be faster than inverted index if a query matches more than %25 of documents." I seriously doubt it. Or my expectations are really off base, which is always possible, I confess I've never measured though. At a high level: indexed: find entry for

Re: Docvalue v.s. invert index

2018-08-13 Thread Mikhail Khludnev
https://github.com/apache/lucene-solr/blob/master/solr/core/src/java/org/apache/solr/schema/FieldType.java#L881 https://github.com/apache/lucene-solr/blob/17eb8cd14d27d2680fe7c4b3871f3eb883542d34/solr/core/src/java/org/apache/solr/search/facet/FacetField.java#L106 On Mon, Aug 13, 2018 at 9:02

Re: Docvalue v.s. invert index

2018-08-13 Thread Zahra Aminolroaya
Thanks Erick, Shawn and Tomoko for complete answers. If I set both docvalue and indexed "true" in a field, will Solr understand to use which technique for faceting or searching? Or Is there any way to inform Solr to use which technique? -- Sent from:

Re: Docvalue v.s. invert index

2018-08-12 Thread Mikhail Khludnev
My expectation is that scanning Doc Values might be faster than inverted index if a query matches more than %25 of documents. On Sun, Aug 12, 2018 at 7:59 PM Erick Erickson wrote: > bq. I have been informed that the performance of such a search is > absolutely terrible. > > Yep. Horrible. > >

Re: Docvalue v.s. invert index

2018-08-12 Thread Erick Erickson
bq. I have been informed that the performance of such a search is absolutely terrible. Yep. Horrible. These two structures answer completely different questions indexed - "for this word, what docs contain it in field X?" DocValues - "for this document, what is the value of field X?" On my, my

Re: Docvalue v.s. invert index

2018-08-12 Thread Shawn Heisey
On 8/12/2018 4:39 AM, Zahra Aminolroaya wrote: Could we say that docvalue technique is better for sorting and faceting and inverted index one is better for searching? Yes.  That is how things work. If docValues do not exist, then an equivalent data structure must be built in heap memory

Re: Docvalue v.s. invert index

2018-08-12 Thread Tomoko Uchida
> Could we say that docvalue technique is better for sorting and faceting and inverted index one is better for searching? The short answer is yes. In addition, there are several special data structures for numeric/date range/geo spatial search.

Docvalue v.s. invert index

2018-08-12 Thread Zahra Aminolroaya
Could we say that docvalue technique is better for sorting and faceting and inverted index one is better for searching? Will I lose anything if I only use docvalue? Does docvalue technique have better performance? -- Sent from: http://lucene.472066.n3.nabble.com/Solr-User-f472068.html