Problem applying sort on ngram field


(Julien Ripault) #1

Hi,

I have encountered a little problem while using sort in a query, I explain.
I index some documents with a string field "label" indexed in a multi field
(one not analyzed and one indexed with n-gram min to 3). I put some
documents in the index including one with a label value length of 3
characters like 'abc'

I try a simple match_all query with a sort on the field 'label', it works
well, all the entries are there including the 'abc' one
If I add a from and size to paginate the results, there is the right number
of results but my entry 'abc' is never returned but other entries appear in
duplicates.

I tried different mappings but it seems to be a combination of pagination,
the sort, ngram and the fact that the value od the field sorted is equals
to the min ngram

Maybe I have missed something

Thanks

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


(system) #2