# Goes through data in a field to parse

**URL:** <https://discuss.elastic.co/t/goes-through-data-in-a-field-to-parse/272429>\
**Category:** Logstash\
**Created:** [May 7, 2021, 2:03pm UTC](https://discuss.elastic.co/t/goes-through-data-in-a-field-to-parse/272429 "2021-05-07T14:03:46Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![lusynda](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lusynda/32/53557_2.png) [@lusynda](https://discuss.elastic.co/u/lusynda)\
**Post date:** [May 7, 2021, 2:03pm UTC](https://discuss.elastic.co/t/goes-through-data-in-a-field-to-parse/272429/1 "2021-05-07T14:03:47Z")

</div>

Hi all  
I have some problems with parse data in logstash

i have a field with value like this:

```auto
testValue: 1,2,3,4

```

and i have an yaml file to map data like this:

```auto
1: some1
2: some2
3: some3

```

i want to parse the data to testValue to map it to its appropriate data. but when i tried, it faled, just fail to map the data.

Has anyone tried this before can some help me.

Thanks for your time.

---

<div class="post-metadata">

**Author:** ![aaron-nimocks](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/aaron-nimocks/32/73965_2.png) [@aaron-nimocks](https://discuss.elastic.co/u/aaron-nimocks)\
**Post date:** [May 7, 2021, 2:26pm UTC](https://discuss.elastic.co/t/goes-through-data-in-a-field-to-parse/272429/2 "2021-05-07T14:26:27Z")

</div>

What have you tried so far? I think the [translate filter](https://www.elastic.co/guide/en/logstash/current/plugins-filters-translate.html) might be what you are looking for.

---

<div class="post-metadata">

**Author:** ![lusynda](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lusynda/32/53557_2.png) [@lusynda](https://discuss.elastic.co/u/lusynda)\
**Post date:** [May 9, 2021, 1:31pm UTC](https://discuss.elastic.co/t/goes-through-data-in-a-field-to-parse/272429/3 "2021-05-09T13:31:53Z")

</div>

Thanks for your replies.  
The translate filter is what i use for this kind of thing but since the data is like what i said above i cannot iterate through the data to map each of it to it appropriate data.

---

<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:** [June 6, 2021, 1:32pm UTC](https://discuss.elastic.co/t/goes-through-data-in-a-field-to-parse/272429/4 "2021-06-06T13:32:52Z")

</div>

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