# No field mapping can be found for the field with name \[\*\]

**URL:** <https://discuss.elastic.co/t/no-field-mapping-can-be-found-for-the-field-with-name/263689>\
**Category:** Elasticsearch\
**Created:** [February 9, 2021, 7:31am UTC](https://discuss.elastic.co/t/no-field-mapping-can-be-found-for-the-field-with-name/263689 "2021-02-09T07:31:00Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jesse\_c](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jesse_c/32/78744_2.png) [@jesse\_c](https://discuss.elastic.co/u/jesse_c)\
**Post date:** [February 9, 2021, 7:31am UTC](https://discuss.elastic.co/t/no-field-mapping-can-be-found-for-the-field-with-name/263689/1 "2021-02-09T07:31:00Z")

</div>

Hi,

I am running into a very strange issue after upgrading to Elasticsearch 7.10.

I keep getting the following error in a particular percolate query:

```
“No field mapping can be found for the field with name [*]”

```

This is only occurring on one shard in particular. The other shards don’t run into this issue.

I’ve narrowed down that the error occurs on this one shard when two fields have two values of string type:

```auto
    “query”: {
      "percolate”: {
         “field”:”query”,
         “document”: {
             “fieldA”:"AB",
             “fieldB”:"AB"
          }
        }
     }

```

1. If I change “AB” to any other random strings (even if they are the same), all shards succeed.
2. If I remove one of the fields, all shards succeed.
3. If either of the fields doesn't have an existing mapping, all shards succeed.

And here is the stacktrace:

```auto
QueryShardException[No field mapping can be found for the field with name [*]]
at org.elasticsearch.index.query.QueryShardContext.failIfFieldMappingNotFound(QueryShardContext.java:309)
at org.elasticsearch.index.query.QueryShardContext.fieldMapper(QueryShardContext.java:253)
at org.elasticsearch.index.search.QueryStringQueryParser.getFieldQuery(QueryStringQueryParser.java:330)
at org.apache.lucene.queryparser.classic.QueryParserBase.handleBareTokenQuery(QueryParserBase.java:830)
at org.apache.lucene.queryparser.classic.QueryParser.Term(QueryParser.java:469)
at org.apache.lucene.queryparser.classic.QueryParser.Clause(QueryParser.java:355)
at org.apache.lucene.queryparser.classic.QueryParser.Query(QueryParser.java:303)
at org.apache.lucene.queryparser.classic.QueryParser.TopLevelQuery(QueryParser.java:215)
at org.apache.lucene.queryparser.classic.QueryParserBase.parse(QueryParserBase.java:109)
at org.elasticsearch.index.search.QueryStringQueryParser.parse(QueryStringQueryParser.java:809)
at org.elasticsearch.index.query.QueryStringQueryBuilder.doToQuery(QueryStringQueryBuilder.java:912)
at org.elasticsearch.index.query.AbstractQueryBuilder.toQuery(AbstractQueryBuilder.java:103)
at org.elasticsearch.percolator.PercolateQueryBuilder.lambda$createStore$8(PercolateQueryBuilder.java:667)
at org.elasticsearch.percolator.PercolateQuery$1$1.matchDocId(PercolateQuery.java:130)
at org.elasticsearch.percolator.PercolateQuery$BaseScorer$1.matches(PercolateQuery.java:286)
at org.apache.lucene.search.Weight$DefaultBulkScorer.scoreRange(Weight.java:250)
at org.apache.lucene.search.Weight$DefaultBulkScorer.score(Weight.java:229)
at org.elasticsearch.search.internal.CancellableBulkScorer.score(CancellableBulkScorer.java:56)
at org.apache.lucene.search.BulkScorer.score(BulkScorer.java:39)
at org.elasticsearch.search.internal.ContextIndexSearcher.searchLeaf(ContextIndexSearcher.java:226)
at org.elasticsearch.search.internal.ContextIndexSearcher.search(ContextIndexSearcher.java:199)
at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:445)
at org.elasticsearch.search.query.QueryPhase.searchWithCollector(QueryPhase.java:343)
at org.elasticsearch.search.query.QueryPhase.executeInternal(QueryPhase.java:298)
at org.elasticsearch.search.query.QueryPhase.execute(QueryPhase.java:150)
at org.elasticsearch.search.SearchService.loadOrExecuteQueryPhase(SearchService.java:362)
at org.elasticsearch.search.SearchService.executeQueryPhase(SearchService.java:435)
at org.elasticsearch.search.SearchService.access$200(SearchService.java:136)
at org.elasticsearch.search.SearchService$2.lambda$onResponse$0(SearchService.java:396)
at org.elasticsearch.search.SearchService.lambda$runAsync$0(SearchService.java:412)
at org.elasticsearch.common.util.concurrent.TimedRunnable.doRun(TimedRunnable.java:44)
at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingAbstractRunnable.doRun(ThreadContext.java:737)at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)

```

It's only when both fields have the associated value "US" that the one shard fails. Do any of you have any ideas as to what may be going on?

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [February 9, 2021, 7:52am UTC](https://discuss.elastic.co/t/no-field-mapping-can-be-found-for-the-field-with-name/263689/2 "2021-02-09T07:52:30Z")

</div>

I do not know the percolator syntax, but the above example is not valid JSON. You are missing a `"` for the fieldA value and lack a comma at the end of the same line. I would recommend showing a couple of full examples of what is and is not working. It is also usually recommended to specify which version of Elasticsearch you are using.

---

<div class="post-metadata">

**Author:** ![jesse\_c](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jesse_c/32/78744_2.png) [@jesse\_c](https://discuss.elastic.co/u/jesse_c)\
**Post date:** [February 9, 2021, 8:04am UTC](https://discuss.elastic.co/t/no-field-mapping-can-be-found-for-the-field-with-name/263689/3 "2021-02-09T08:04:49Z")

</div>

Thanks. I updated my original message.

---

<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:** [March 9, 2021, 8:05am UTC](https://discuss.elastic.co/t/no-field-mapping-can-be-found-for-the-field-with-name/263689/4 "2021-03-09T08:05:30Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
