# CSV filter plugin config file error

**URL:** <https://discuss.elastic.co/t/csv-filter-plugin-config-file-error/49451>\
**Category:** Logstash\
**Created:** [May 7, 2016, 3:08am UTC](https://discuss.elastic.co/t/csv-filter-plugin-config-file-error/49451 "2016-05-07T03:08:18Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![gmackers](https://avatars.discourse-cdn.com/v4/letter/g/4491bb/32.png) [@gmackers](https://discuss.elastic.co/u/gmackers)\
**Post date:** [May 7, 2016, 3:08am UTC](https://discuss.elastic.co/t/csv-filter-plugin-config-file-error/49451/1 "2016-05-07T03:08:18Z")

</div>

Hi, newbie logstasher here. I'm trying to run my first logstash instance and having a problem with the config file. When I add a "convert" property to my CSV filter config I get an error.

This is fine:  
convert =\> { "When" =\> "date"}

This is not:  
convert =\> { "When" =\> "date", "LocalTime" =\> "date"}

It gives the following error starting logstash:  
"The given configuration is invalid. Reason: Expected on of #, {, } at line..."

In the CSV filter docs it says I can define multiple converts with this syntax, but my logstash will not allow it. Any ideas what I'm doing wrong?

Running on Windows 8.1 with Java version 1.8.0\_66.

Cheers,

G.

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [May 7, 2016, 6:25am UTC](https://discuss.elastic.co/t/csv-filter-plugin-config-file-error/49451/2 "2016-05-07T06:25:37Z")

</div>

Can you show your entire config?

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [May 8, 2016, 7:51pm UTC](https://discuss.elastic.co/t/csv-filter-plugin-config-file-error/49451/3 "2016-05-08T19:51:56Z")

</div>

> convert =\> { "When" =\> "date", "LocalTime" =\> "date"}

Remove the space between each key/value pair.

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [May 8, 2016, 8:41pm UTC](https://discuss.elastic.co/t/csv-filter-plugin-config-file-error/49451/4 "2016-05-08T20:41:53Z")

</div>

Dunno, this works for me;

```auto
  mutate {
    convert => {
      "average_lifespan" => "integer"
      "average_height" => "integer"
      "people" => "string"
    }
  }

```

---

<div class="post-metadata">

**Author:** ![gmackers](https://avatars.discourse-cdn.com/v4/letter/g/4491bb/32.png) [@gmackers](https://discuss.elastic.co/u/gmackers)\
**Post date:** [May 9, 2016, 10:35pm UTC](https://discuss.elastic.co/t/csv-filter-plugin-config-file-error/49451/5 "2016-05-09T22:35:00Z")

</div>

Thanks warkolm, your solution worked.  
Regards,  
Greg

---

<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:** [July 6, 2017, 4:58am UTC](https://discuss.elastic.co/t/csv-filter-plugin-config-file-error/49451/6 "2017-07-06T04:58:28Z")

</div>

Closed on July 6, 2017, 4:58am UTC


