# Creating field names based on entry position

**URL:** <https://discuss.elastic.co/t/creating-field-names-based-on-entry-position/131010>\
**Category:** Logstash\
**Created:** [May 8, 2018, 1:15pm UTC](https://discuss.elastic.co/t/creating-field-names-based-on-entry-position/131010 "2018-05-08T13:15:27Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![motts](https://avatars.discourse-cdn.com/v4/letter/m/839c29/32.png) [@motts](https://discuss.elastic.co/u/motts)\
**Post date:** [May 8, 2018, 1:15pm UTC](https://discuss.elastic.co/t/creating-field-names-based-on-entry-position/131010/1 "2018-05-08T13:15:27Z")

</div>

I have some interesting data to work with. I have a plain text file with Windows Events in it which some lines contain a field and value, while other lines only contain a value. The data is in json format and looks like this:

> \r\nMay 07 09:14:08 2018\r\n665\r\nSecurity\r\n...

665 would be the Event ID  
Security would be the Event Type

The logs don't have a field for those values, but they are always at the same spot in the log; the date is the 4th entry, 665 is the 5th, Security is the 6th, etc. Is there a good way to go about getting the data to be displayed like this in the end:

```
EventID: 665
EventType: Security

```

Many thanks

---

<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 5, 2018, 1:15pm UTC](https://discuss.elastic.co/t/creating-field-names-based-on-entry-position/131010/2 "2018-06-05T13:15:28Z")

</div>

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