# Separate fields and values in logstash

**URL:** <https://discuss.elastic.co/t/separate-fields-and-values-in-logstash/226155>\
**Category:** Logstash\
**Created:** [April 2, 2020, 5:59am UTC](https://discuss.elastic.co/t/separate-fields-and-values-in-logstash/226155 "2020-04-02T05:59:19Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![newbie001](https://avatars.discourse-cdn.com/v4/letter/n/c77e96/32.png) [@newbie001](https://discuss.elastic.co/u/newbie001)\
**Post date:** [April 2, 2020, 5:59am UTC](https://discuss.elastic.co/t/separate-fields-and-values-in-logstash/226155/1 "2020-04-02T05:59:19Z")

</div>

Hi - I need help on how I can separate the fields and values via logstash. I'm not sure if grok filter is applicable on this as it only separates the values of the fields. Please see below my sample input and expected output.

**Sample Input:**

#CustomerName,Age,Gender,Status  
Jennifer 39 Female Married

#Temperature,Humidity,Precipitation  
72.1 0.113 85.1

**Expected Output:**

Customer Name = Jennifer  
Age = 39  
Gender = Female  
Status = Married  
Temperature = 72.1  
Humidity = 0.113  
Precipitation = 85.1

Thanks in advance!

---

<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:** [April 30, 2020, 6:00am UTC](https://discuss.elastic.co/t/separate-fields-and-values-in-logstash/226155/2 "2020-04-30T06:00:22Z")

</div>

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