Skip to content

Instantly share code, notes, and snippets.

@zopyx
Created June 7, 2013 11:47
Show Gist options
  • Save zopyx/5728721 to your computer and use it in GitHub Desktop.
Save zopyx/5728721 to your computer and use it in GitHub Desktop.
{'query': {'bool': {'must': {'prefix': {u'title': u'bread'},
'range': {u'protein': {'from': '1',
'to': '2'}}}}},
'size': 15,
'sort': {'position': {'title': 'asc'}}}
ElasticHttpError: (500, u'SearchPhaseExecutionException[Failed to execute phase [query], total failure; shardFailures {[MG6BRnNeRLy8c2rLTv_TFw][food][2]: SearchParseException[[food][2]: from[-1],size[-1],sort[<custom:"position": org.elasticsearch.index.field.data.longs.LongFieldDataType$1@5512520e>]: Parse Failure [Failed to parse source [{"sort": {"position": {"title": "asc"}}, "query": {"bool": {"must": {"range": {"protein": {"to": "2", "from": "1"}}, "prefix": {"title": "bread"}}}}, "size": 15}]]]; nested: QueryParsingException[[food] [_na] query malformed, no field after start_object]; }{[MG6BRnNeRLy8c2rLTv_TFw][food][4]: SearchParseException[[food][4]: from[-1],size[-1],sort[<custom:"position": org.elasticsearch.index.field.data.longs.LongFieldDataType$1@17249727>]: Parse Failure [Failed to parse source [{"sort": {"position": {"title": "asc"}}, "query": {"bool": {"must": {"range": {"protein": {"to": "2", "from": "1"}}, "prefix": {"title": "bread"}}}}, "size": 15}]]]; nested: QueryParsingException[[food] [_na] query malformed, no field after start_object]; }]')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment