elasticsearch - Auto Complete is not working in Elastic Search -


if give exact match or 1 character working fine, if give 2 or 3 characters auto complete not working. example if give t or test working, if give tes not working.

my data looks this

put /test/test/1 {     "id": "1",     "input": "test",     "output": ["testing", "testing"] }  put /test/test/2 {     "id": "2",     "input": "test two",     "output":["testing", "testing"] } 

my elastic query

{     "query": {         "query_string": {             "query": "tes"         }     } } 

you forgot wildcard believe:

get /test/test/_search {     "query": {         "query_string": {             "query": "tes*"         }     } } 

you may want use "query": "input:tes*" autocomplete 1 specific field.


Comments

Popular posts from this blog

python - How to insert QWidgets in the middle of a Layout? -

python - serve multiple gunicorn django instances under nginx ubuntu -

module - Prestashop displayPaymentReturn hook url -