Why is my very simple ElasticSearch query failing, SearchPhaseExecutionException -


im trying search "dog chew" in invention-title field in patentgrants type.
query url: post http://localhost:9200/patents/patentgrants/_search
query body:

{   "query": {     "match_all": {       "invention-title": "dog chew"     }   } } 

below picture of data in patents index , below picture of query , error message. picture of information in patents index

my query , resulting exception message

try this:

{   "query": {     "match": {       "inventiontitle": "dog chew"     }   } } 
  1. the field name in screenshot inventiontitle not invention-title.
  2. https://www.elastic.co/guide/en/elasticsearch/reference/1.6/query-dsl-match-all-query.html - use match instead of match_all. match_all doesn't accept search query.

Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

jquery - javascript onscroll fade same class but with different div -