# More\_like\_this not using nested fields?

**URL:** <https://discuss.elastic.co/t/more-like-this-not-using-nested-fields/296311>\
**Category:** Elasticsearch\
**Created:** [February 4, 2022, 2:27pm UTC](https://discuss.elastic.co/t/more-like-this-not-using-nested-fields/296311 "2022-02-04T14:27:47Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![ndtreviv](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ndtreviv/32/22494_2.png) [@ndtreviv](https://discuss.elastic.co/u/ndtreviv)\
**Post date:** [February 4, 2022, 2:27pm UTC](https://discuss.elastic.co/t/more-like-this-not-using-nested-fields/296311/1 "2022-02-04T14:27:47Z")

</div>

I want to use the more like this query type to find similar documents without having to construct a bool. I like the `minimum_should_match` as a percent to identify %-similar documents.

My document has lots of nested fields. For example, I have a nested document specified in the mapping like this:

```auto
...
      "screenshot": {
        "type": "nested",
        "properties": {
          "md5": {
            "type": "keyword",
            "store": true
          },
          "pdq": {
            "type": "keyword",
            "store": true
          },
          "pdqId": {
            "type": "long"
          },
          "src": {
            "type": "text",
            "term_vector": "yes"
          },
          "extension": {
            "type": "keyword",
            "store": true
          },
          "mimeType": {
            "type": "keyword",
            "store": true
          }
        }
      },
...

```

I really want the `src` field to be used in MLT queries, but my tests indicate that it isn't.

How can I make that happen? Do I need to have `include_in_root` on the mapping for that field to make that happen?

Thanks for any help offered!

---

<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 4, 2022, 2:28pm UTC](https://discuss.elastic.co/t/more-like-this-not-using-nested-fields/296311/2 "2022-03-04T14:28:06Z")

</div>

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