In elasticsearch 1.3.0 *filtered* not working with *has_parent*. In *elasticsearch 0.90.5* its working fine.
I am using below query. In this query I need add filtered inside *has_parent->query->filtered->bool->must*. But my basic query is not working. { "query": { "has_parent": { "parent_type": "url", "query": { "match": { "affiliate_id": "1718489511" } } }, "filtered": { "filter": { "bool": { "must": { "terms": { "country": [ "india" ] } } } } } } } Getting error message* ElasticsearchParseException[Expected field name but got START_OBJECT "filtered"* *Complete Error Message:-* error: SearchPhaseExecutionException[Failed to execute phase [query], all shards failed; shardFailures {[hZgYLUmsQL2T8z1MY2eyNA][esindex][5]: SearchParseException[[esindex][5]: query[parent_filter[url](filtered(affiliate_id:1718489511)->cache(_type :url))],from[-1],size[-1]: Parse Failure [Failed to parse source [{"query":{"has_parent":{ "parent_type":"url","query":{"match":{"affiliate_id":"1718489511"}}}, "filtered":{"filter":{"bool":{"must":{"terms":{"country":["india" ]}}}}}}}]]]; nested: ElasticsearchParseException[Expected field name but got START_OBJECT "filtered"]; } {[OPG4zuQlQr2dFxUvRe2GWg][esindex][4]: RemoteTransportException[[ server1][inet[/127.0.0.1:9300]] [search/phase/query]]; nested: SearchParseException[[esindex][4]: query [parent_filter[url] (filtered(affiliate_id:1718489511)->cache(_type:url))],from[-1],size[-1 ]: Parse Failure [Failed to parse source [{"query":{"has_parent":{"parent_type":"url", "query":{"match":{"affiliate_id":"1718489511"}}}, "filtered":{"filter":{"bool":{"must":{"terms":{"country":["india" ]}}}}}}}]]]; nested: ElasticsearchParseException[Expected field name but got START_OBJECT "filtered"]; } Any suggestion? -- 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+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/683129a1-c757-4250-a97e-a15a4efbbaa5%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.