# Term query no hits was Re: No parser for element \[term\]

**URL:** <https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707>\
**Category:** Elasticsearch\
**Created:** [July 16, 2014, 5:21pm UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707 "2014-07-16T17:21:29Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![jackpark](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jackpark](https://discuss.elastic.co/u/jackpark)\
**Post date:** [July 16, 2014, 5:21pm UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707/1 "2014-07-16T17:21:29Z")

</div>

Thank you very much. I was in the process of drafting a message that I  
found that and made the query to look like these:

{"query":{"term":{"label":""First instance node""}}}  
{"query":{"term":{"inOf":"NodeBuilderType"}}}

Neither returns any hits.  
In the same system, I did a text search with this query:  
{"query":{"multi\_match":{"query":"topic map","fields":["details","label"]}}}

and that worked perfectly.  
So, I have two open issues:  
1- what's wrong with term query?  
2- there were 145 hits on the text search; need to configure the query  
to do paging through those hits.

Many thanks for this help  
Jack

On Wed, Jul 16, 2014 at 9:48 AM, David Pilato [david@pilato.fr](mailto:david@pilato.fr) wrote:

> You need to put it in a query.
> 
> Have a look at  
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/guide/current/search.html)
> 
> --  
> David 😉  
> Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> 
> Le 16 juil. 2014 à 18:04, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org) a écrit :
> 
> This exact query is not found in the list, so here goes. Just upgraded to  
> 1.2.2.
> 
> The query documentation  
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl-term-query.html)  
> gives this example:
> 
> {  
> "term" : { "user" : "kimchy" }  
> }
> 
> So, my querydsl written for nodejs is this:
> 
> {"term":{"inOf":"NodeBuilderType"}}
> 
> I happen to know that documents satisfying that query exist, for instance:  
> {"lox":"NodeBuilderSecondTopic","crtr":"SystemUser","sIco":"","lIco":"","crDt":"2014-07-16T08:45:21","srtDt":1405525521801,"lEdDt":"2014-07-16T08:45:21","isPrv":"false","label":["First  
> instance node"],"details":["Seems  
> likely"],"inOf":"NodeBuilderType","trCl",["NodeBuilderType","ASuperClass"],"sbOf":["ASuperClass"]}
> 
> What I get back is an enormous stack trace, a portion of which from  
> the error log below.
> 
> Am I missing something?
> 
> Many thanks in advance.  
> Jack
> 
> [2014-07-16 08:53:20.332] [ERROR] TopicMap - DP.\_\_listNodesByQuery  
> {"term":{"inOf":"NodeBuilderType"}} | Error:  
> {"error":"SearchPhaseExecutionException[Failed to execute phase  
> [query], all shards failed; shardFailures  
> {[cawnH8a8S32Bpl96txGwyw][topics][2]:  
> SearchParseException[[topics][2]: from[-1],size[-1]: Parse Failure  
> [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> nested: SearchParseException[[topics][2]: from[-1],size[-1]: Parse  
> Failure [No parser for element [term]]];  
> }{[cawnH8a8S32Bpl96txGwyw][topics][3]:  
> SearchParseException[[topics][3]: from[-1],size[-1]: Parse Failure  
> [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> nested: SearchParseException[[topics][3]: from[-1],size[-1]: Parse  
> Failure [No parser for element [term]]];  
> }{[cawnH8a8S32Bpl96txGwyw][topics][0]:  
> SearchParseException[[topics][0]: from[-1],size[-1]: Parse Failure  
> [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> nested: SearchParseException[[topics][0]: from[-1],size[-1]: Parse  
> Failure [No parser for element [term]]];  
> }{[cawnH8a8S32Bpl96txGwyw][topics][1]:  
> SearchParseException[[topics][1]: from[-1],size[-1]: Parse Failure  
> [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> nested: SearchParseException[[topics][1]: from[-1],size[-1]: Parse  
> Failure [No parser for element [term]]];  
> }{[cawnH8a8S32Bpl96txGwyw][topics][4]:  
> SearchParseException[[topics][4]: from[-1],size[-1]: Parse Failure  
> [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> nested: SearchParseException[[topics][4]: from[-1],size[-1]: Parse  
> Failure [No parser for element [term]]]; }]","status":400}
> 
> --  
> 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je\_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com).  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> --  
> 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr](https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr).  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW\_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Ivan](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Ivan](https://discuss.elastic.co/u/Ivan)\
**Post date:** [July 16, 2014, 5:27pm UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707/2 "2014-07-16T17:27:54Z")

</div>

By default, string fields are analyzed using the standard analyzer, which  
will tokenize and lowercase the input (I believe stop words are now NOT  
removed). A term query does not analyze the query, so it only works on non  
analyzed fields (or fields that use a keyword tokenizer). A term query for  
"kimchy" works because it already is lowercased and only has one token.

Try using a match query or set the field to be non analyzed. The choice  
depends on your other use cases (do you require partial matching?).

Cheers,

Ivan

On Wed, Jul 16, 2014 at 10:21 AM, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org)  
wrote:

> Thank you very much. I was in the process of drafting a message that I  
> found that and made the query to look like these:
> 
> {"query":{"term":{"label":""First instance node""}}}  
> {"query":{"term":{"inOf":"NodeBuilderType"}}}
> 
> Neither returns any hits.  
> In the same system, I did a text search with this query:  
> {"query":{"multi\_match":{"query":"topic  
> map","fields":["details","label"]}}}
> 
> and that worked perfectly.  
> So, I have two open issues:  
> 1- what's wrong with term query?  
> 2- there were 145 hits on the text search; need to configure the query  
> to do paging through those hits.
> 
> Many thanks for this help  
> Jack
> 
> On Wed, Jul 16, 2014 at 9:48 AM, David Pilato [david@pilato.fr](mailto:david@pilato.fr) wrote:
> 
> > You need to put it in a query.
> > 
> > Have a look at
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/guide/current/search.html)
> 
> > --  
> > David 😉  
> > Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> > 
> > Le 16 juil. 2014 à 18:04, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org) a écrit :
> > 
> > This exact query is not found in the list, so here goes. Just upgraded to  
> > 1.2.2.
> > 
> > The query documentation
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl-term-query.html)
> 
> > gives this example:
> > 
> > {  
> > "term" : { "user" : "kimchy" }  
> > }
> > 
> > So, my querydsl written for nodejs is this:
> > 
> > {"term":{"inOf":"NodeBuilderType"}}
> > 
> > I happen to know that documents satisfying that query exist, for  
> > instance:
> 
> {"lox":"NodeBuilderSecondTopic","crtr":"SystemUser","sIco":"","lIco":"","crDt":"2014-07-16T08:45:21","srtDt":1405525521801,"lEdDt":"2014-07-16T08:45:21","isPrv":"false","label":["First
> 
> > instance node"],"details":["Seems
> 
> likely"],"inOf":"NodeBuilderType","trCl",["NodeBuilderType","ASuperClass"],"sbOf":["ASuperClass"]}
> 
> > What I get back is an enormous stack trace, a portion of which from  
> > the error log below.
> > 
> > Am I missing something?
> > 
> > Many thanks in advance.  
> > Jack
> > 
> > [2014-07-16 08:53:20.332] [ERROR] TopicMap - DP.\_\_listNodesByQuery  
> > {"term":{"inOf":"NodeBuilderType"}} | Error:  
> > {"error":"SearchPhaseExecutionException[Failed to execute phase  
> > [query], all shards failed; shardFailures  
> > {[cawnH8a8S32Bpl96txGwyw][topics][2]:  
> > SearchParseException[[topics][2]: from[-1],size[-1]: Parse Failure  
> > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > nested: SearchParseException[[topics][2]: from[-1],size[-1]: Parse  
> > Failure [No parser for element [term]]];  
> > }{[cawnH8a8S32Bpl96txGwyw][topics][3]:  
> > SearchParseException[[topics][3]: from[-1],size[-1]: Parse Failure  
> > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > nested: SearchParseException[[topics][3]: from[-1],size[-1]: Parse  
> > Failure [No parser for element [term]]];  
> > }{[cawnH8a8S32Bpl96txGwyw][topics][0]:  
> > SearchParseException[[topics][0]: from[-1],size[-1]: Parse Failure  
> > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > nested: SearchParseException[[topics][0]: from[-1],size[-1]: Parse  
> > Failure [No parser for element [term]]];  
> > }{[cawnH8a8S32Bpl96txGwyw][topics][1]:  
> > SearchParseException[[topics][1]: from[-1],size[-1]: Parse Failure  
> > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > nested: SearchParseException[[topics][1]: from[-1],size[-1]: Parse  
> > Failure [No parser for element [term]]];  
> > }{[cawnH8a8S32Bpl96txGwyw][topics][4]:  
> > SearchParseException[[topics][4]: from[-1],size[-1]: Parse Failure  
> > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > nested: SearchParseException[[topics][4]: from[-1],size[-1]: Parse  
> > Failure [No parser for element [term]]]; }]","status":400}
> > 
> > --  
> > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je\_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com)  
> .
> 
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > 
> > --  
> > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr](https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr)  
> .
> 
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> --  
> 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW\_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![jackpark](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jackpark](https://discuss.elastic.co/u/jackpark)\
**Post date:** [July 16, 2014, 5:43pm UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707/3 "2014-07-16T17:43:42Z")

</div>

Thanks Ivan.

That term query on the label field was, in fact on an analyzed field.  
What is of concern at the moment is that this query:  
{"query":{"term":{"inOf":"NodeBuilderType"}}}  
is on an unanalyzed field, defined thus:

```
    "inOf": {
        "index": "not_analyzed",
        "type": "string",
        "store": "yes"
    },

```

If all the ducks are lined up, it's not clear what the problem is for  
that query.

On Wed, Jul 16, 2014 at 10:27 AM, Ivan Brusic [ivan@brusic.com](mailto:ivan@brusic.com) wrote:

> By default, string fields are analyzed using the standard analyzer, which  
> will tokenize and lowercase the input (I believe stop words are now NOT  
> removed). A term query does not analyze the query, so it only works on non  
> analyzed fields (or fields that use a keyword tokenizer). A term query for  
> "kimchy" works because it already is lowercased and only has one token.
> 
> Try using a match query or set the field to be non analyzed. The choice  
> depends on your other use cases (do you require partial matching?).
> 
> Cheers,
> 
> Ivan
> 
> On Wed, Jul 16, 2014 at 10:21 AM, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org)  
> wrote:
> 
> > Thank you very much. I was in the process of drafting a message that I  
> > found that and made the query to look like these:
> > 
> > {"query":{"term":{"label":""First instance node""}}}  
> > {"query":{"term":{"inOf":"NodeBuilderType"}}}
> > 
> > Neither returns any hits.  
> > In the same system, I did a text search with this query:  
> > {"query":{"multi\_match":{"query":"topic  
> > map","fields":["details","label"]}}}
> > 
> > and that worked perfectly.  
> > So, I have two open issues:  
> > 1- what's wrong with term query?  
> > 2- there were 145 hits on the text search; need to configure the query  
> > to do paging through those hits.
> > 
> > Many thanks for this help  
> > Jack
> > 
> > On Wed, Jul 16, 2014 at 9:48 AM, David Pilato [david@pilato.fr](mailto:david@pilato.fr) wrote:
> > 
> > > You need to put it in a query.
> > > 
> > > Have a look at
> > > 
> > > [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/guide/current/search.html)
> > > 
> > > --  
> > > David 😉  
> > > Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> > > 
> > > Le 16 juil. 2014 à 18:04, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org) a écrit :
> > > 
> > > This exact query is not found in the list, so here goes. Just upgraded  
> > > to  
> > > 1.2.2.
> > > 
> > > The query documentation
> > > 
> > > [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl-term-query.html)  
> > > gives this example:
> > > 
> > > {  
> > > "term" : { "user" : "kimchy" }  
> > > }
> > > 
> > > So, my querydsl written for nodejs is this:
> > > 
> > > {"term":{"inOf":"NodeBuilderType"}}
> > > 
> > > I happen to know that documents satisfying that query exist, for  
> > > instance:
> > > 
> > > {"lox":"NodeBuilderSecondTopic","crtr":"SystemUser","sIco":"","lIco":"","crDt":"2014-07-16T08:45:21","srtDt":1405525521801,"lEdDt":"2014-07-16T08:45:21","isPrv":"false","label":["First  
> > > instance node"],"details":["Seems
> > > 
> > > likely"],"inOf":"NodeBuilderType","trCl",["NodeBuilderType","ASuperClass"],"sbOf":["ASuperClass"]}
> > > 
> > > What I get back is an enormous stack trace, a portion of which from  
> > > the error log below.
> > > 
> > > Am I missing something?
> > > 
> > > Many thanks in advance.  
> > > Jack
> > > 
> > > [2014-07-16 08:53:20.332] [ERROR] TopicMap - DP.\_\_listNodesByQuery  
> > > {"term":{"inOf":"NodeBuilderType"}} | Error:  
> > > {"error":"SearchPhaseExecutionException[Failed to execute phase  
> > > [query], all shards failed; shardFailures  
> > > {[cawnH8a8S32Bpl96txGwyw][topics][2]:  
> > > SearchParseException[[topics][2]: from[-1],size[-1]: Parse Failure  
> > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > nested: SearchParseException[[topics][2]: from[-1],size[-1]: Parse  
> > > Failure [No parser for element [term]]];  
> > > }{[cawnH8a8S32Bpl96txGwyw][topics][3]:  
> > > SearchParseException[[topics][3]: from[-1],size[-1]: Parse Failure  
> > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > nested: SearchParseException[[topics][3]: from[-1],size[-1]: Parse  
> > > Failure [No parser for element [term]]];  
> > > }{[cawnH8a8S32Bpl96txGwyw][topics][0]:  
> > > SearchParseException[[topics][0]: from[-1],size[-1]: Parse Failure  
> > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > nested: SearchParseException[[topics][0]: from[-1],size[-1]: Parse  
> > > Failure [No parser for element [term]]];  
> > > }{[cawnH8a8S32Bpl96txGwyw][topics][1]:  
> > > SearchParseException[[topics][1]: from[-1],size[-1]: Parse Failure  
> > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > nested: SearchParseException[[topics][1]: from[-1],size[-1]: Parse  
> > > Failure [No parser for element [term]]];  
> > > }{[cawnH8a8S32Bpl96txGwyw][topics][4]:  
> > > SearchParseException[[topics][4]: from[-1],size[-1]: Parse Failure  
> > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > nested: SearchParseException[[topics][4]: from[-1],size[-1]: Parse  
> > > Failure [No parser for element [term]]]; }]","status":400}
> > > 
> > > --  
> > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > To view this discussion on the web visit
> > > 
> > > [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je\_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com).  
> > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > 
> > > --  
> > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > To view this discussion on the web visit
> > > 
> > > [https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr](https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr).  
> > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > 
> > --  
> > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > To view this discussion on the web visit  
> > [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW\_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com).
> > 
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> --  
> 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com).
> 
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyv%2B%2BrhcnG%3DNgFDo-pr7XTOsLbEOfvXO5QA\_10OTEt5Zg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyv%2B%2BrhcnG%3DNgFDo-pr7XTOsLbEOfvXO5QA_10OTEt5Zg%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Ivan](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Ivan](https://discuss.elastic.co/u/Ivan)\
**Post date:** [July 16, 2014, 6:00pm UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707/4 "2014-07-16T18:00:35Z")

</div>

I would verify that the field is in fact non\_analyzed and that your data is  
indexed in the way you think it is. Use the analyze API to analyze the  
term. Make sure you use the last example, which is based on the field.

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

A term query will do an exact match. If your field is in fact correct, post  
an example mapping and document.

Cheers,

Ivan

On Wed, Jul 16, 2014 at 10:43 AM, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org)  
wrote:

> Thanks Ivan.
> 
> That term query on the label field was, in fact on an analyzed field.  
> What is of concern at the moment is that this query:  
> {"query":{"term":{"inOf":"NodeBuilderType"}}}  
> is on an unanalyzed field, defined thus:
> 
> ```
> "inOf": {
> "index": "not_analyzed",
> "type": "string",
> "store": "yes"
> },
> 
> ```
> 
> If all the ducks are lined up, it's not clear what the problem is for  
> that query.
> 
> On Wed, Jul 16, 2014 at 10:27 AM, Ivan Brusic [ivan@brusic.com](mailto:ivan@brusic.com) wrote:
> 
> > By default, string fields are analyzed using the standard analyzer, which  
> > will tokenize and lowercase the input (I believe stop words are now NOT  
> > removed). A term query does not analyze the query, so it only works on  
> > non  
> > analyzed fields (or fields that use a keyword tokenizer). A term query  
> > for  
> > "kimchy" works because it already is lowercased and only has one token.
> > 
> > Try using a match query or set the field to be non analyzed. The choice  
> > depends on your other use cases (do you require partial matching?).
> > 
> > Cheers,
> > 
> > Ivan
> > 
> > On Wed, Jul 16, 2014 at 10:21 AM, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org)  
> > wrote:
> > 
> > > Thank you very much. I was in the process of drafting a message that I  
> > > found that and made the query to look like these:
> > > 
> > > {"query":{"term":{"label":""First instance node""}}}  
> > > {"query":{"term":{"inOf":"NodeBuilderType"}}}
> > > 
> > > Neither returns any hits.  
> > > In the same system, I did a text search with this query:  
> > > {"query":{"multi\_match":{"query":"topic  
> > > map","fields":["details","label"]}}}
> > > 
> > > and that worked perfectly.  
> > > So, I have two open issues:  
> > > 1- what's wrong with term query?  
> > > 2- there were 145 hits on the text search; need to configure the query  
> > > to do paging through those hits.
> > > 
> > > Many thanks for this help  
> > > Jack
> > > 
> > > On Wed, Jul 16, 2014 at 9:48 AM, David Pilato [david@pilato.fr](mailto:david@pilato.fr) wrote:
> > > 
> > > > You need to put it in a query.
> > > > 
> > > > Have a look at
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/guide/current/search.html)
> 
> > > > --  
> > > > David 😉  
> > > > Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> > > > 
> > > > Le 16 juil. 2014 à 18:04, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org) a  
> > > > écrit :
> > > > 
> > > > This exact query is not found in the list, so here goes. Just upgraded  
> > > > to  
> > > > 1.2.2.
> > > > 
> > > > The query documentation
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl-term-query.html)
> 
> > > > gives this example:
> > > > 
> > > > {  
> > > > "term" : { "user" : "kimchy" }  
> > > > }
> > > > 
> > > > So, my querydsl written for nodejs is this:
> > > > 
> > > > {"term":{"inOf":"NodeBuilderType"}}
> > > > 
> > > > I happen to know that documents satisfying that query exist, for  
> > > > instance:
> 
> {"lox":"NodeBuilderSecondTopic","crtr":"SystemUser","sIco":"","lIco":"","crDt":"2014-07-16T08:45:21","srtDt":1405525521801,"lEdDt":"2014-07-16T08:45:21","isPrv":"false","label":["First
> 
> > > > instance node"],"details":["Seems
> 
> likely"],"inOf":"NodeBuilderType","trCl",["NodeBuilderType","ASuperClass"],"sbOf":["ASuperClass"]}
> 
> > > > What I get back is an enormous stack trace, a portion of which from  
> > > > the error log below.
> > > > 
> > > > Am I missing something?
> > > > 
> > > > Many thanks in advance.  
> > > > Jack
> > > > 
> > > > [2014-07-16 08:53:20.332] [ERROR] TopicMap - DP.\_\_listNodesByQuery  
> > > > {"term":{"inOf":"NodeBuilderType"}} | Error:  
> > > > {"error":"SearchPhaseExecutionException[Failed to execute phase  
> > > > [query], all shards failed; shardFailures  
> > > > {[cawnH8a8S32Bpl96txGwyw][topics][2]:  
> > > > SearchParseException[[topics][2]: from[-1],size[-1]: Parse Failure  
> > > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > nested: SearchParseException[[topics][2]: from[-1],size[-1]: Parse  
> > > > Failure [No parser for element [term]]];  
> > > > }{[cawnH8a8S32Bpl96txGwyw][topics][3]:  
> > > > SearchParseException[[topics][3]: from[-1],size[-1]: Parse Failure  
> > > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > nested: SearchParseException[[topics][3]: from[-1],size[-1]: Parse  
> > > > Failure [No parser for element [term]]];  
> > > > }{[cawnH8a8S32Bpl96txGwyw][topics][0]:  
> > > > SearchParseException[[topics][0]: from[-1],size[-1]: Parse Failure  
> > > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > nested: SearchParseException[[topics][0]: from[-1],size[-1]: Parse  
> > > > Failure [No parser for element [term]]];  
> > > > }{[cawnH8a8S32Bpl96txGwyw][topics][1]:  
> > > > SearchParseException[[topics][1]: from[-1],size[-1]: Parse Failure  
> > > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > nested: SearchParseException[[topics][1]: from[-1],size[-1]: Parse  
> > > > Failure [No parser for element [term]]];  
> > > > }{[cawnH8a8S32Bpl96txGwyw][topics][4]:  
> > > > SearchParseException[[topics][4]: from[-1],size[-1]: Parse Failure  
> > > > [Failed to parse source [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > nested: SearchParseException[[topics][4]: from[-1],size[-1]: Parse  
> > > > Failure [No parser for element [term]]]; }]","status":400}
> > > > 
> > > > --  
> > > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je\_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com)  
> .
> 
> > > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > > 
> > > > --  
> > > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr](https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr)  
> .
> 
> > > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > 
> > > --  
> > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW\_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com)  
> .
> 
> > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > 
> > --  
> > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com)  
> .
> 
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> --  
> 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyv%2B%2BrhcnG%3DNgFDo-pr7XTOsLbEOfvXO5QA\_10OTEt5Zg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyv%2B%2BrhcnG%3DNgFDo-pr7XTOsLbEOfvXO5QA_10OTEt5Zg%40mail.gmail.com)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAVgrOvA0qPeU5teETaZ\_a8ukTLf\_2MeKsbsCO0tx-jfw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAVgrOvA0qPeU5teETaZ_a8ukTLf_2MeKsbsCO0tx-jfw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![jackpark](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jackpark](https://discuss.elastic.co/u/jackpark)\
**Post date:** [July 16, 2014, 8:42pm UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707/5 "2014-07-16T20:42:37Z")

</div>

What I know at the moment is this: If I change "term" to "match", it  
gets the right answers.  
In some sense, that suggests that even though my mappings.json says  
that the field is not-analyzed, it's behaving as if it has been  
analyzed.

On Wed, Jul 16, 2014 at 11:00 AM, Ivan Brusic [ivan@brusic.com](mailto:ivan@brusic.com) wrote:

> I would verify that the field is in fact non\_analyzed and that your data is  
> indexed in the way you think it is. Use the analyze API to analyze the term.  
> Make sure you use the last example, which is based on the field.
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/indices-analyze.html)
> 
> A term query will do an exact match. If your field is in fact correct, post  
> an example mapping and document.
> 
> Cheers,
> 
> Ivan
> 
> On Wed, Jul 16, 2014 at 10:43 AM, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org)  
> wrote:
> 
> > Thanks Ivan.
> > 
> > That term query on the label field was, in fact on an analyzed field.  
> > What is of concern at the moment is that this query:  
> > {"query":{"term":{"inOf":"NodeBuilderType"}}}  
> > is on an unanalyzed field, defined thus:
> > 
> > ```
> > "inOf": {
> > "index": "not_analyzed",
> > "type": "string",
> > "store": "yes"
> > },
> > 
> > ```
> > 
> > If all the ducks are lined up, it's not clear what the problem is for  
> > that query.
> > 
> > On Wed, Jul 16, 2014 at 10:27 AM, Ivan Brusic [ivan@brusic.com](mailto:ivan@brusic.com) wrote:
> > 
> > > By default, string fields are analyzed using the standard analyzer,  
> > > which  
> > > will tokenize and lowercase the input (I believe stop words are now NOT  
> > > removed). A term query does not analyze the query, so it only works on  
> > > non  
> > > analyzed fields (or fields that use a keyword tokenizer). A term query  
> > > for  
> > > "kimchy" works because it already is lowercased and only has one token.
> > > 
> > > Try using a match query or set the field to be non analyzed. The choice  
> > > depends on your other use cases (do you require partial matching?).
> > > 
> > > Cheers,
> > > 
> > > Ivan
> > > 
> > > On Wed, Jul 16, 2014 at 10:21 AM, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org)  
> > > wrote:
> > > 
> > > > Thank you very much. I was in the process of drafting a message that I  
> > > > found that and made the query to look like these:
> > > > 
> > > > {"query":{"term":{"label":""First instance node""}}}  
> > > > {"query":{"term":{"inOf":"NodeBuilderType"}}}
> > > > 
> > > > Neither returns any hits.  
> > > > In the same system, I did a text search with this query:  
> > > > {"query":{"multi\_match":{"query":"topic  
> > > > map","fields":["details","label"]}}}
> > > > 
> > > > and that worked perfectly.  
> > > > So, I have two open issues:  
> > > > 1- what's wrong with term query?  
> > > > 2- there were 145 hits on the text search; need to configure the query  
> > > > to do paging through those hits.
> > > > 
> > > > Many thanks for this help  
> > > > Jack
> > > > 
> > > > On Wed, Jul 16, 2014 at 9:48 AM, David Pilato [david@pilato.fr](mailto:david@pilato.fr) wrote:
> > > > 
> > > > > You need to put it in a query.
> > > > > 
> > > > > Have a look at
> > > > > 
> > > > > [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/guide/current/search.html)
> > > > > 
> > > > > --  
> > > > > David 😉  
> > > > > Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> > > > > 
> > > > > Le 16 juil. 2014 à 18:04, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org) a  
> > > > > écrit :
> > > > > 
> > > > > This exact query is not found in the list, so here goes. Just  
> > > > > upgraded  
> > > > > to  
> > > > > 1.2.2.
> > > > > 
> > > > > The query documentation
> > > > > 
> > > > > [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl-term-query.html)  
> > > > > gives this example:
> > > > > 
> > > > > {  
> > > > > "term" : { "user" : "kimchy" }  
> > > > > }
> > > > > 
> > > > > So, my querydsl written for nodejs is this:
> > > > > 
> > > > > {"term":{"inOf":"NodeBuilderType"}}
> > > > > 
> > > > > I happen to know that documents satisfying that query exist, for  
> > > > > instance:
> > > > > 
> > > > > {"lox":"NodeBuilderSecondTopic","crtr":"SystemUser","sIco":"","lIco":"","crDt":"2014-07-16T08:45:21","srtDt":1405525521801,"lEdDt":"2014-07-16T08:45:21","isPrv":"false","label":["First  
> > > > > instance node"],"details":["Seems
> > > > > 
> > > > > likely"],"inOf":"NodeBuilderType","trCl",["NodeBuilderType","ASuperClass"],"sbOf":["ASuperClass"]}
> > > > > 
> > > > > What I get back is an enormous stack trace, a portion of which from  
> > > > > the error log below.
> > > > > 
> > > > > Am I missing something?
> > > > > 
> > > > > Many thanks in advance.  
> > > > > Jack
> > > > > 
> > > > > [2014-07-16 08:53:20.332] [ERROR] TopicMap - DP.\_\_listNodesByQuery  
> > > > > {"term":{"inOf":"NodeBuilderType"}} | Error:  
> > > > > {"error":"SearchPhaseExecutionException[Failed to execute phase  
> > > > > [query], all shards failed; shardFailures  
> > > > > {[cawnH8a8S32Bpl96txGwyw][topics][2]:  
> > > > > SearchParseException[[topics][2]: from[-1],size[-1]: Parse Failure  
> > > > > [Failed to parse source  
> > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > nested: SearchParseException[[topics][2]: from[-1],size[-1]: Parse  
> > > > > Failure [No parser for element [term]]];  
> > > > > }{[cawnH8a8S32Bpl96txGwyw][topics][3]:  
> > > > > SearchParseException[[topics][3]: from[-1],size[-1]: Parse Failure  
> > > > > [Failed to parse source  
> > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > nested: SearchParseException[[topics][3]: from[-1],size[-1]: Parse  
> > > > > Failure [No parser for element [term]]];  
> > > > > }{[cawnH8a8S32Bpl96txGwyw][topics][0]:  
> > > > > SearchParseException[[topics][0]: from[-1],size[-1]: Parse Failure  
> > > > > [Failed to parse source  
> > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > nested: SearchParseException[[topics][0]: from[-1],size[-1]: Parse  
> > > > > Failure [No parser for element [term]]];  
> > > > > }{[cawnH8a8S32Bpl96txGwyw][topics][1]:  
> > > > > SearchParseException[[topics][1]: from[-1],size[-1]: Parse Failure  
> > > > > [Failed to parse source  
> > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > nested: SearchParseException[[topics][1]: from[-1],size[-1]: Parse  
> > > > > Failure [No parser for element [term]]];  
> > > > > }{[cawnH8a8S32Bpl96txGwyw][topics][4]:  
> > > > > SearchParseException[[topics][4]: from[-1],size[-1]: Parse Failure  
> > > > > [Failed to parse source  
> > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > nested: SearchParseException[[topics][4]: from[-1],size[-1]: Parse  
> > > > > Failure [No parser for element [term]]]; }]","status":400}
> > > > > 
> > > > > --  
> > > > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > > > To view this discussion on the web visit
> > > > > 
> > > > > [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je\_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com).  
> > > > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > > > 
> > > > > --  
> > > > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > > > To view this discussion on the web visit
> > > > > 
> > > > > [https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr](https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr).  
> > > > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > > 
> > > > --  
> > > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > > To view this discussion on the web visit
> > > > 
> > > > [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW\_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com).
> > > > 
> > > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > 
> > > --  
> > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > To view this discussion on the web visit
> > > 
> > > [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com).
> > > 
> > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > 
> > --  
> > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > To view this discussion on the web visit  
> > [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyv%2B%2BrhcnG%3DNgFDo-pr7XTOsLbEOfvXO5QA\_10OTEt5Zg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyv%2B%2BrhcnG%3DNgFDo-pr7XTOsLbEOfvXO5QA_10OTEt5Zg%40mail.gmail.com).
> > 
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> --  
> 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAVgrOvA0qPeU5teETaZ\_a8ukTLf\_2MeKsbsCO0tx-jfw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAVgrOvA0qPeU5teETaZ_a8ukTLf_2MeKsbsCO0tx-jfw%40mail.gmail.com).
> 
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fwfdukUo4\_QQQg0g\_aJPrsZfhib6bvHxE-b8U%2B-UeGCug%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fwfdukUo4_QQQg0g_aJPrsZfhib6bvHxE-b8U%2B-UeGCug%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Ivan](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Ivan](https://discuss.elastic.co/u/Ivan)\
**Post date:** [July 16, 2014, 9:15pm UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707/6 "2014-07-16T21:15:19Z")

</div>

Do not rely on what your mapping template says and use the get mapping API  
to find out what the mapping really is:

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

Since many settings cannot be changed after an index is created, older  
settings can be in effect.

--  
Ivan

On Wed, Jul 16, 2014 at 1:42 PM, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org) wrote:

> What I know at the moment is this: If I change "term" to "match", it  
> gets the right answers.  
> In some sense, that suggests that even though my mappings.json says  
> that the field is not-analyzed, it's behaving as if it has been  
> analyzed.
> 
> On Wed, Jul 16, 2014 at 11:00 AM, Ivan Brusic [ivan@brusic.com](mailto:ivan@brusic.com) wrote:
> 
> > I would verify that the field is in fact non\_analyzed and that your data  
> > is  
> > indexed in the way you think it is. Use the analyze API to analyze the  
> > term.  
> > Make sure you use the last example, which is based on the field.
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/indices-analyze.html)
> 
> > A term query will do an exact match. If your field is in fact correct,  
> > post  
> > an example mapping and document.
> > 
> > Cheers,
> > 
> > Ivan
> > 
> > On Wed, Jul 16, 2014 at 10:43 AM, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org)  
> > wrote:
> > 
> > > Thanks Ivan.
> > > 
> > > That term query on the label field was, in fact on an analyzed field.  
> > > What is of concern at the moment is that this query:  
> > > {"query":{"term":{"inOf":"NodeBuilderType"}}}  
> > > is on an unanalyzed field, defined thus:
> > > 
> > > ```
> > > "inOf": {
> > > "index": "not_analyzed",
> > > "type": "string",
> > > "store": "yes"
> > > },
> > > 
> > > ```
> > > 
> > > If all the ducks are lined up, it's not clear what the problem is for  
> > > that query.
> > > 
> > > On Wed, Jul 16, 2014 at 10:27 AM, Ivan Brusic [ivan@brusic.com](mailto:ivan@brusic.com) wrote:
> > > 
> > > > By default, string fields are analyzed using the standard analyzer,  
> > > > which  
> > > > will tokenize and lowercase the input (I believe stop words are now  
> > > > NOT  
> > > > removed). A term query does not analyze the query, so it only works on  
> > > > non  
> > > > analyzed fields (or fields that use a keyword tokenizer). A term query  
> > > > for  
> > > > "kimchy" works because it already is lowercased and only has one  
> > > > token.
> > > > 
> > > > Try using a match query or set the field to be non analyzed. The  
> > > > choice  
> > > > depends on your other use cases (do you require partial matching?).
> > > > 
> > > > Cheers,
> > > > 
> > > > Ivan
> > > > 
> > > > On Wed, Jul 16, 2014 at 10:21 AM, Jack Park \<[jackpark@topicquests.org](mailto:jackpark@topicquests.org)
> > 
> > > > wrote:
> > > > 
> > > > > Thank you very much. I was in the process of drafting a message that  
> > > > > I  
> > > > > found that and made the query to look like these:
> > > > > 
> > > > > {"query":{"term":{"label":""First instance node""}}}  
> > > > > {"query":{"term":{"inOf":"NodeBuilderType"}}}
> > > > > 
> > > > > Neither returns any hits.  
> > > > > In the same system, I did a text search with this query:  
> > > > > {"query":{"multi\_match":{"query":"topic  
> > > > > map","fields":["details","label"]}}}
> > > > > 
> > > > > and that worked perfectly.  
> > > > > So, I have two open issues:  
> > > > > 1- what's wrong with term query?  
> > > > > 2- there were 145 hits on the text search; need to configure the  
> > > > > query  
> > > > > to do paging through those hits.
> > > > > 
> > > > > Many thanks for this help  
> > > > > Jack
> > > > > 
> > > > > On Wed, Jul 16, 2014 at 9:48 AM, David Pilato [david@pilato.fr](mailto:david@pilato.fr)  
> > > > > wrote:
> > > > > 
> > > > > > You need to put it in a query.
> > > > > > 
> > > > > > Have a look at
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/guide/current/search.html)
> 
> > > > > > --  
> > > > > > David 😉  
> > > > > > Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> > > > > > 
> > > > > > Le 16 juil. 2014 à 18:04, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org) a  
> > > > > > écrit :
> > > > > > 
> > > > > > This exact query is not found in the list, so here goes. Just  
> > > > > > upgraded  
> > > > > > to  
> > > > > > 1.2.2.
> > > > > > 
> > > > > > The query documentation
> 
> [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl-term-query.html)
> 
> > > > > > gives this example:
> > > > > > 
> > > > > > {  
> > > > > > "term" : { "user" : "kimchy" }  
> > > > > > }
> > > > > > 
> > > > > > So, my querydsl written for nodejs is this:
> > > > > > 
> > > > > > {"term":{"inOf":"NodeBuilderType"}}
> > > > > > 
> > > > > > I happen to know that documents satisfying that query exist, for  
> > > > > > instance:
> 
> {"lox":"NodeBuilderSecondTopic","crtr":"SystemUser","sIco":"","lIco":"","crDt":"2014-07-16T08:45:21","srtDt":1405525521801,"lEdDt":"2014-07-16T08:45:21","isPrv":"false","label":["First
> 
> > > > > > instance node"],"details":["Seems
> 
> likely"],"inOf":"NodeBuilderType","trCl",["NodeBuilderType","ASuperClass"],"sbOf":["ASuperClass"]}
> 
> > > > > > What I get back is an enormous stack trace, a portion of which from  
> > > > > > the error log below.
> > > > > > 
> > > > > > Am I missing something?
> > > > > > 
> > > > > > Many thanks in advance.  
> > > > > > Jack
> > > > > > 
> > > > > > [2014-07-16 08:53:20.332] [ERROR] TopicMap - DP.\_\_listNodesByQuery  
> > > > > > {"term":{"inOf":"NodeBuilderType"}} | Error:  
> > > > > > {"error":"SearchPhaseExecutionException[Failed to execute phase  
> > > > > > [query], all shards failed; shardFailures  
> > > > > > {[cawnH8a8S32Bpl96txGwyw][topics][2]:  
> > > > > > SearchParseException[[topics][2]: from[-1],size[-1]: Parse Failure  
> > > > > > [Failed to parse source  
> > > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > > nested: SearchParseException[[topics][2]: from[-1],size[-1]: Parse  
> > > > > > Failure [No parser for element [term]]];  
> > > > > > }{[cawnH8a8S32Bpl96txGwyw][topics][3]:  
> > > > > > SearchParseException[[topics][3]: from[-1],size[-1]: Parse Failure  
> > > > > > [Failed to parse source  
> > > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > > nested: SearchParseException[[topics][3]: from[-1],size[-1]: Parse  
> > > > > > Failure [No parser for element [term]]];  
> > > > > > }{[cawnH8a8S32Bpl96txGwyw][topics][0]:  
> > > > > > SearchParseException[[topics][0]: from[-1],size[-1]: Parse Failure  
> > > > > > [Failed to parse source  
> > > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > > nested: SearchParseException[[topics][0]: from[-1],size[-1]: Parse  
> > > > > > Failure [No parser for element [term]]];  
> > > > > > }{[cawnH8a8S32Bpl96txGwyw][topics][1]:  
> > > > > > SearchParseException[[topics][1]: from[-1],size[-1]: Parse Failure  
> > > > > > [Failed to parse source  
> > > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > > nested: SearchParseException[[topics][1]: from[-1],size[-1]: Parse  
> > > > > > Failure [No parser for element [term]]];  
> > > > > > }{[cawnH8a8S32Bpl96txGwyw][topics][4]:  
> > > > > > SearchParseException[[topics][4]: from[-1],size[-1]: Parse Failure  
> > > > > > [Failed to parse source  
> > > > > > [{"term":{"inOf":"NodeBuilderType"}}]]];  
> > > > > > nested: SearchParseException[[topics][4]: from[-1],size[-1]: Parse  
> > > > > > Failure [No parser for element [term]]]; }]","status":400}
> > > > > > 
> > > > > > --  
> > > > > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > > > > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je\_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fw%3D2T3VpUa3-Ok4je_W6s6HW-dcZcEJ6qztk-v0PxjuzA%40mail.gmail.com)  
> .
> 
> > > > > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > > > > 
> > > > > > --  
> > > > > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > > > > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr](https://groups.google.com/d/msgid/elasticsearch/977768D7-AFC8-40B6-8521-23C174341B38%40pilato.fr)  
> .
> 
> > > > > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > > > 
> > > > > --  
> > > > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > > > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW\_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyqrsFK5bbGW_rZMq%2BYa2UDR8yPPod0grgoHySGweBSyg%40mail.gmail.com)  
> .
> 
> > > > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > > 
> > > > --  
> > > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAKxFSqj1Fxv6r4NYnzs44-GXAzkLZKghSTq5FfhZL7nw%40mail.gmail.com)  
> .
> 
> > > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > 
> > > --  
> > > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyv%2B%2BrhcnG%3DNgFDo-pr7XTOsLbEOfvXO5QA\_10OTEt5Zg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fyv%2B%2BrhcnG%3DNgFDo-pr7XTOsLbEOfvXO5QA_10OTEt5Zg%40mail.gmail.com)  
> .
> 
> > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > 
> > --  
> > 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > To view this discussion on the web visit
> 
> [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAVgrOvA0qPeU5teETaZ\_a8ukTLf\_2MeKsbsCO0tx-jfw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAVgrOvA0qPeU5teETaZ_a8ukTLf_2MeKsbsCO0tx-jfw%40mail.gmail.com)  
> .
> 
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> --  
> 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fwfdukUo4\_QQQg0g\_aJPrsZfhib6bvHxE-b8U%2B-UeGCug%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fwfdukUo4_QQQg0g_aJPrsZfhib6bvHxE-b8U%2B-UeGCug%40mail.gmail.com)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAyVTxadvwxCb\_a%2B1Hi%3DY1mSZpRszgwROuis6iVu7cgmA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQAyVTxadvwxCb_a%2B1Hi%3DY1mSZpRszgwROuis6iVu7cgmA%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![jackpark](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jackpark](https://discuss.elastic.co/u/jackpark)\
**Post date:** [July 16, 2014, 9:33pm UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707/7 "2014-07-16T21:33:50Z")

</div>

Here are the mappings I dumped by adding that function to my client:

{"topics":{"mappings":{"core":{"properties":{"crDt":{"type":"date","format":"dat  
eOptionalTime"},"crtr":{"type":"string"},"details":{"type":"string"},"inOf":{"ty  
pe":"string"},"isPrv":{"type":"string"},"lEdDt":{"type":"date","format":"dateOpt  
ionalTime"},"lIco":{"type":"string"},"label":{"type":"string"},"lox":{"type":"st  
ring"},"sIco":{"type":"string"},"sbOf":{"type":"string"},"srtDt":{"type":"long"}  
,"trCl":{"type":"string"}}}}}}

There are no fields for "index" or "store" where  
"index":"not\_analyzed" was used where appropriate.

A snippet of the mappings.json is below. I would like to know why ES  
ignored the values.

Many thanks  
Jack

{  
"properties": {  
"lox": {  
"index": "not\_analyzed",  
"type": "string",  
"store": "yes"  
},  
"inOf": {  
"index": "not\_analyzed",  
"type": "string",  
"store": "yes"  
},  
"\_ver": {  
"index": "not\_analyzed",  
"type": "string",  
"store": "yes"  
},  
"srtDt": {  
"index": "not\_analyzed",  
"type": "long",  
"store": "yes"  
},  
"tpC": {  
"index": "not\_analyzed",  
"type": "long",  
"store": "yes"  
},  
"lists": {  
"properties": {  
"sbOf": {  
"index": "not\_analyzed",  
"type": "string",  
"store": "yes"  
},  
"label": {  
"index": "analyzed",  
"type": "string",  
"store": "yes"  
},  
"details": {  
"index": "analyzed",  
"type": "string",  
"store": "yes"  
}

--  
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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fwvc\_yvfx91nsJiu3-etTHTza5DMkdjyWmM92u5R\_VXSg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fwvc_yvfx91nsJiu3-etTHTza5DMkdjyWmM92u5R_VXSg%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Ivan](https://avatars.discourse-cdn.com/v4/letter/i/df788c/32.png) [@Ivan](https://discuss.elastic.co/u/Ivan)\
**Post date:** [July 16, 2014, 11:29pm UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707/8 "2014-07-16T23:29:01Z")

</div>

As predicted, your actual mapping does not match your perceived mapping.

Something is not matching up. Perhaps the mapping is for a different index  
or type. Best way is to share your mapping and perhaps how you created your  
index as indicated at [Elasticsearch Platform — Find real-time answers at scale | Elastic](http://www.elasticsearch.org/help)

--  
Ivan

On Wed, Jul 16, 2014 at 2:33 PM, Jack Park [jackpark@topicquests.org](mailto:jackpark@topicquests.org) wrote:

> Here are the mappings I dumped by adding that function to my client:
> 
> {"topics":{"mappings":{"core":{"properties":{"crDt":{"type":"date","format":"dat
> 
> eOptionalTime"},"crtr":{"type":"string"},"details":{"type":"string"},"inOf":{"ty
> 
> pe":"string"},"isPrv":{"type":"string"},"lEdDt":{"type":"date","format":"dateOpt
> 
> ionalTime"},"lIco":{"type":"string"},"label":{"type":"string"},"lox":{"type":"st
> 
> ring"},"sIco":{"type":"string"},"sbOf":{"type":"string"},"srtDt":{"type":"long"}  
> ,"trCl":{"type":"string"}}}}}}
> 
> There are no fields for "index" or "store" where  
> "index":"not\_analyzed" was used where appropriate.
> 
> A snippet of the mappings.json is below. I would like to know why ES  
> ignored the values.
> 
> Many thanks  
> Jack
> 
> {  
> "properties": {  
> "lox": {  
> "index": "not\_analyzed",  
> "type": "string",  
> "store": "yes"  
> },  
> "inOf": {  
> "index": "not\_analyzed",  
> "type": "string",  
> "store": "yes"  
> },  
> "\_ver": {  
> "index": "not\_analyzed",  
> "type": "string",  
> "store": "yes"  
> },  
> "srtDt": {  
> "index": "not\_analyzed",  
> "type": "long",  
> "store": "yes"  
> },  
> "tpC": {  
> "index": "not\_analyzed",  
> "type": "long",  
> "store": "yes"  
> },  
> "lists": {  
> "properties": {  
> "sbOf": {  
> "index": "not\_analyzed",  
> "type": "string",  
> "store": "yes"  
> },  
> "label": {  
> "index": "analyzed",  
> "type": "string",  
> "store": "yes"  
> },  
> "details": {  
> "index": "analyzed",  
> "type": "string",  
> "store": "yes"  
> }
> 
> --  
> 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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CAH6s0fwvc\_yvfx91nsJiu3-etTHTza5DMkdjyWmM92u5R\_VXSg%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAH6s0fwvc_yvfx91nsJiu3-etTHTza5DMkdjyWmM92u5R_VXSg%40mail.gmail.com)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQCP8PPLbj46sDk%2Bad-3GmjW7HN5nS7WONcZ9T8yR9m%2BOw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CALY%3DcQCP8PPLbj46sDk%2Bad-3GmjW7HN5nS7WONcZ9T8yR9m%2BOw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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, 1:15am UTC](https://discuss.elastic.co/t/term-query-no-hits-was-re-no-parser-for-element-term/18707/9 "2017-07-06T01:15:17Z")

</div>


