# Field \[content\] not present as part of path \[content\] when update\_by\_query

**URL:** <https://discuss.elastic.co/t/field-content-not-present-as-part-of-path-content-when-update-by-query/313336>\
**Category:** Elasticsearch\
**Created:** [August 31, 2022, 9:01am UTC](https://discuss.elastic.co/t/field-content-not-present-as-part-of-path-content-when-update-by-query/313336 "2022-08-31T09:01:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![sherry\_cs](https://avatars.discourse-cdn.com/v4/letter/s/c89c15/32.png) [@sherry\_cs](https://discuss.elastic.co/u/sherry_cs)\
**Post date:** [August 31, 2022, 9:01am UTC](https://discuss.elastic.co/t/field-content-not-present-as-part-of-path-content-when-update-by-query/313336/1 "2022-08-31T09:01:00Z")

</div>

Hi, guys. I created an index with a pipeline which extracted field from the file attachments.  
It works well except the partial update. I tried the request :

```auto
POST test_know/_update/G3LH2oIBXGHwpDNidXe9
{
  "doc": {
    "file_name": "new name"
  }
}

```

And the response:

```auto

{
  "error" : {
    "root_cause" : [
      {
        "type" : "illegal_argument_exception",
        "reason" : "field [content] not present as part of path [content]"
      }
    ],
    "type" : "illegal_argument_exception",
    "reason" : "field [content] not present as part of path [content]"
  },
  "status" : 400
}

```

The mapping looks like:

```auto

{
  "mappings": {
    "_doc": {
      "properties": {
        "attachment": {
          "properties": {
            "author": {
              "type": "text",
              "fields": {
                "keyword": {
                  "type": "keyword",
                  "ignore_above": 256
                }
              }
            },
            "content": {
              "type": "text",
              "fields": {
                "keyword": {
                  "type": "keyword",
                  "ignore_above": 256
                }
              }
            },
            "content_length": {
              "type": "long"
            },
            "content_type": {
              "type": "text",
              "fields": {
                "keyword": {
                  "type": "keyword",
                  "ignore_above": 256
                }
              }
            },
            "date": {
              "type": "date"
            },
            "language": {
              "type": "text",
              "fields": {
                "keyword": {
                  "type": "keyword",
                  "ignore_above": 256
                }
              }
            },
            "title": {
              "type": "text",
              "fields": {
                "keyword": {
                  "type": "keyword",
                  "ignore_above": 256
                }
              }
            }
          }
        },
        "author": {
          "type": "text",
          "fields": {
            "keyword": {
              "type": "keyword",
              "ignore_above": 256
            }
          }
        },     
        "file_name": {
          "type": "text",
          "fields": {
            "keyword": {
              "type": "keyword",
              "ignore_above": 256
            }
          }
        }
  }
}

```

So what can I do to solve the problem? Many thanks!

---

<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 28, 2022, 9:01am UTC](https://discuss.elastic.co/t/field-content-not-present-as-part-of-path-content-when-update-by-query/313336/2 "2022-09-28T09:01:39Z")

</div>

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