# Logstash doesn't Import CSV columns correctly

**URL:** <https://discuss.elastic.co/t/logstash-doesnt-import-csv-columns-correctly/179253>\
**Category:** Logstash\
**Created:** [May 1, 2019, 8:41pm UTC](https://discuss.elastic.co/t/logstash-doesnt-import-csv-columns-correctly/179253 "2019-05-01T20:41:38Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ac3](https://avatars.discourse-cdn.com/v4/letter/a/3ab097/32.png) [@Ac3](https://discuss.elastic.co/u/Ac3)\
**Post date:** [May 1, 2019, 8:41pm UTC](https://discuss.elastic.co/t/logstash-doesnt-import-csv-columns-correctly/179253/1 "2019-05-01T20:41:38Z")

</div>

Hi  
I am importing some IP data stored in CSV into ELK using Logstash. When I view the data in Kibana however the columns are all over the place and they are formatted fine in the CSV?

Kibana Screenshot

![image](https://us1.discourse-cdn.com/elastic/original/3X/7/9/791a182ec304d5d901770f23f179bf73c6f0e850.png)

Does ELK struggle with Blank cells or special charters???

Logstash Config:

```
else if [path] == "C:/ProgramData/FDA/output/processed/OSINT.csv"{
	csv {
        separator => ","
        columns => ["city", "region_code", "os", "ip", "isp", "area_code","dma_code", "last_update", "country_code3", "country_name", "hostnames", "postal_code", "longitude", "country_code", "ip_str", "latitude", "org"]
    }
}

```

CSV data

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/2/9/298c1d72f0767f31408c0b27c9efc3f6e4239d71.png)

Any Ideas?

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [May 1, 2019, 9:15pm UTC](https://discuss.elastic.co/t/logstash-doesnt-import-csv-columns-correctly/179253/2 "2019-05-01T21:15:38Z")

</div>

You left out "tags" in your columns option for the csv filter.

---

<div class="post-metadata">

**Author:** ![Ac3](https://avatars.discourse-cdn.com/v4/letter/a/3ab097/32.png) [@Ac3](https://discuss.elastic.co/u/Ac3)\
**Post date:** [May 1, 2019, 10:49pm UTC](https://discuss.elastic.co/t/logstash-doesnt-import-csv-columns-correctly/179253/3 "2019-05-01T22:49:00Z")

</div>

Thanks again @Badger Can't believe i miss this.....

---

<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:** [May 29, 2019, 10:49pm UTC](https://discuss.elastic.co/t/logstash-doesnt-import-csv-columns-correctly/179253/4 "2019-05-29T22:49:10Z")

</div>

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