# ElasticSearch version 7.14.0 can't highlight with search\_as\_you\_type datatype subfield

**URL:** <https://discuss.elastic.co/t/elasticsearch-version-7-14-0-cant-highlight-with-search-as-you-type-datatype-subfield/283005>\
**Category:** Elasticsearch\
**Created:** [September 1, 2021, 7:57am UTC](https://discuss.elastic.co/t/elasticsearch-version-7-14-0-cant-highlight-with-search-as-you-type-datatype-subfield/283005 "2021-09-01T07:57:33Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![andrewbien](https://avatars.discourse-cdn.com/v4/letter/a/b2d939/32.png) [@andrewbien](https://discuss.elastic.co/u/andrewbien)\
**Post date:** [September 1, 2021, 7:57am UTC](https://discuss.elastic.co/t/elasticsearch-version-7-14-0-cant-highlight-with-search-as-you-type-datatype-subfield/283005/1 "2021-09-01T07:57:33Z")

</div>

Here is my example to reproduce the problem:

```auto
PUT mytest
{
  "mappings": {
    "properties": {
      "title": {
        "type": "keyword", 
        "fields": {
          "autocomplete": {
            "type": "search_as_you_type"
          }
        }
      },
      "name": {
        "type": "keyword", 
        "fields": {
          "text": {
            "type": "text"
          }
        }
      },
      "myauto": {
        "type": "search_as_you_type"
      }
    }
  }
}

```

```auto
POST mytest/_doc/1
{
  "title": "go to school",
  "name": "new way",
  "myauto": "go to school"
}

```

```auto
POST mytest/_doc/2
{
  "title": "I love you",
  "name": "love",
  "myauto": "I love you"
}

```

When I use version 7.9.0, highlight worked fine with the query bellow:

```auto
GET mytest/_search
{
  "_source": [],
  "query": {
    "multi_match": {
      "boost": 0.9,
      "fields": [
        "title.autocomplete",
        "title.autocomplete._2gram",
        "title.autocomplete._3gram"
      ],
      "fuzziness": 1,
      "query": "school",
      "type": "bool_prefix"
    }
  },
  "highlight": {
    "fields": {
      "title.autocomplete._index_prefix": {}
    }
  }
}

```

But on version 7.14.0, I can't get a highlight on the result with the same query above.  
I don't know what happened with the new version. I Hope will get help from the community. Thanks in advance.

---

<div class="post-metadata">

**Author:** ![andrewbien](https://avatars.discourse-cdn.com/v4/letter/a/b2d939/32.png) [@andrewbien](https://discuss.elastic.co/u/andrewbien)\
**Post date:** [September 1, 2021, 1:17pm UTC](https://discuss.elastic.co/t/elasticsearch-version-7-14-0-cant-highlight-with-search-as-you-type-datatype-subfield/283005/2 "2021-09-01T13:17:05Z")

</div>

Does anyone know this issue?? 🙂

---

<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:** [September 29, 2021, 1:17pm UTC](https://discuss.elastic.co/t/elasticsearch-version-7-14-0-cant-highlight-with-search-as-you-type-datatype-subfield/283005/3 "2021-09-29T13:17:50Z")

</div>

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