# Ingest pipeline processor split

**URL:** <https://discuss.elastic.co/t/ingest-pipeline-processor-split/103890>\
**Category:** Elasticsearch\
**Created:** [October 13, 2017, 12:09pm UTC](https://discuss.elastic.co/t/ingest-pipeline-processor-split/103890 "2017-10-13T12:09:04Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Taoufiq\_BOUKHCHA](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/taoufiq_boukhcha/32/22993_2.png) [@Taoufiq\_BOUKHCHA](https://discuss.elastic.co/u/Taoufiq_BOUKHCHA)\
**Post date:** [October 13, 2017, 12:09pm UTC](https://discuss.elastic.co/t/ingest-pipeline-processor-split/103890/1 "2017-10-13T12:09:04Z")

</div>

Hi, when I specify the `target_field` in the split processor I get the following error:

```auto
{
   "error": {
      "root_cause": [
         {
            "type": "parse_exception",
            "reason": "processor [split] doesn't support one or more provided configuration parameters [target_field]",
            "header": {
               "processor_type": "split",
               "processor_tag": "splitMessageProcessor"
            }
         }
      ],
      "type": "parse_exception",
      "reason": "processor [split] doesn't support one or more provided configuration parameters [target_field]",
      "header": {
         "processor_type": "split",
         "processor_tag": "splitMessageProcessor"
      }
   },
   "status": 400
}

```

My test simulation in ES 5.5:

```auto
POST _ingest/pipeline/_simulate
{
  "pipeline": {
  "description" : "pipeline for online services",
      "processors": [
        {
          "split": {
            "field": "message",
             "tag": "splitMessageProcessor",
            "separator": "\\s+",
            "target_field": "splitedMessage"
          }
        }
      ]
    },
  "docs": [
    {
      "_source": { "message": "A B C" }
    }
  ]
}

```

it works without `target_field`, but I don't want to replace the existing field. Is this an issue?

---

<div class="post-metadata">

**Author:** ![abdon](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/abdon/32/9195_2.png) [@abdon](https://discuss.elastic.co/u/abdon)\
**Post date:** [October 13, 2017, 12:34pm UTC](https://discuss.elastic.co/t/ingest-pipeline-processor-split/103890/2 "2017-10-13T12:34:05Z")

</div>

According to the documentation, `target_field` was introduced in version 5.6. Are you on an older version?

If so, you could first copy the value of `message` to another field using the `set` processor and then split that target field. The following should work:

```
POST _ingest/pipeline/_simulate
{
  "pipeline": {
    "description": "pipeline for online services",
    "processors": [
      {
        "set": {
          "field": "splitedMessage",
          "value": "{{message}}"
        }
      },
      {
        "split": {
          "field": "splitedMessage",
          "tag": "splitMessageProcessor",
          "separator": "\\s+"
        }
      }
    ]
  },
  "docs": [
    {
      "_source": {
        "message": "A B C"
      }
    }
  ]
}
```

---

<div class="post-metadata">

**Author:** ![Taoufiq\_BOUKHCHA](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/taoufiq_boukhcha/32/22993_2.png) [@Taoufiq\_BOUKHCHA](https://discuss.elastic.co/u/Taoufiq_BOUKHCHA)\
**Post date:** [October 13, 2017, 1:09pm UTC](https://discuss.elastic.co/t/ingest-pipeline-processor-split/103890/3 "2017-10-13T13:09:05Z")

</div>

ah! yes, I use 5.5

thanks for the work around.

---

<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:** [November 10, 2017, 1:09pm UTC](https://discuss.elastic.co/t/ingest-pipeline-processor-split/103890/4 "2017-11-10T13:09:07Z")

</div>

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