# No parser for element \[filtered\]

**URL:** https://discuss.elastic.co/t/no-parser-for-element-filtered/5226
**Category:** Elasticsearch
**Created:** [August 23, 2011, 11:04am UTC](https://discuss.elastic.co/t/no-parser-for-element-filtered/5226 "2011-08-23T11:04:11Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Ridvan\_Gyundogan](https://avatars.discourse-cdn.com/v4/letter/r/e495f1/32.png) [@Ridvan\_Gyundogan](https://discuss.elastic.co/u/Ridvan_Gyundogan)
#### Post date: [August 23, 2011, 11:04am UTC](https://discuss.elastic.co/t/no-parser-for-element-filtered/5226/1 "2011-08-23T11:04:11Z")

</div>

Hello, I need a filtered query like described here  
[http://www.elasticsearch.org/guide/reference/query-dsl/filtered-query.html](http://www.elasticsearch.org/guide/reference/query-dsl/filtered-query.html)  
but I get an error saying No parser for element [filtered].

This is the gist of my query and error: [https://gist.github.com/1164853](https://gist.github.com/1164853)

I use ES version 17.4 .

Any help will be very much appreciated.

---

<div class="post-metadata">

### Author: ![Ridvan\_Gyundogan](https://avatars.discourse-cdn.com/v4/letter/r/e495f1/32.png) [@Ridvan\_Gyundogan](https://discuss.elastic.co/u/Ridvan_Gyundogan)
#### Post date: [August 23, 2011, 3:20pm UTC](https://discuss.elastic.co/t/no-parser-for-element-filtered/5226/2 "2011-08-23T15:20:20Z")

</div>

ok Ignore this it looks like a problem in elasticsearch-head.

On Aug 23, 2:04 pm, Ridvan Gyundogan [ridva...@gmail.com](mailto:ridva...@gmail.com) wrote:

> Hello, I need a filtered query like described herehttp://www.elasticsearch.org/guide/reference/query-dsl/filtered-query...  
> but I get an error saying No parser for element [filtered].
> 
> This is the gist of my query and error:[the error · GitHub](https://gist.github.com/1164853)
> 
> I use ES version 17.4 .
> 
> Any help will be very much appreciated.

---

<div class="post-metadata">

### Author: ![Clinton\_Gormley](https://avatars.discourse-cdn.com/v4/letter/c/50afbb/32.png) [@Clinton\_Gormley](https://discuss.elastic.co/u/Clinton_Gormley)
#### Post date: [August 24, 2011, 7:51am UTC](https://discuss.elastic.co/t/no-parser-for-element-filtered/5226/3 "2011-08-24T07:51:46Z")

</div>

On Tue, 2011-08-23 at 04:04 -0700, Ridvan Gyundogan wrote:

> Hello, I need a filtered query like described here  
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/reference/query-dsl/filtered-query.html)  
> but I get an error saying No parser for element [filtered].
> 
> This is the gist of my query and error: [the error · GitHub](https://gist.github.com/1164853)

the "filtered" clause should be wrapped in an outer "query" clause:

{ "query": { "filtered": { .... } }}

clint

---

<div class="post-metadata">

### Author: ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)
#### Post date: [August 24, 2011, 6:17pm UTC](https://discuss.elastic.co/t/no-parser-for-element-filtered/5226/4 "2011-08-24T18:17:53Z")

</div>

On Wed, Aug 24, 2011 at 10:51 AM, Clinton Gormley [clint@traveljury.com](mailto:clint@traveljury.com)wrote:

> On Tue, 2011-08-23 at 04:04 -0700, Ridvan Gyundogan wrote:
> 
> > Hello, I need a filtered query like described here
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/reference/query-dsl/filtered-query.html)
> 
> > but I get an error saying No parser for element [filtered].
> > 
> > This is the gist of my query and error: [the error · GitHub](https://gist.github.com/1164853)
> 
> the "filtered" clause should be wrapped in an outer "query" clause:
> 
> { "query": { "filtered": { .... } }}

Only for the top level search API 🙂

> clint

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [July 6, 2017, 3:56am UTC](https://discuss.elastic.co/t/no-parser-for-element-filtered/5226/5 "2017-07-06T03:56:11Z")

</div>


