# How to pull a field from an event to another event?

**URL:** <https://discuss.elastic.co/t/how-to-pull-a-field-from-an-event-to-another-event/34235>\
**Category:** Logstash\
**Created:** [November 10, 2015, 12:02pm UTC](https://discuss.elastic.co/t/how-to-pull-a-field-from-an-event-to-another-event/34235 "2015-11-10T12:02:11Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![jjdepaul](https://avatars.discourse-cdn.com/v4/letter/j/e0b2c6/32.png) [@jjdepaul](https://discuss.elastic.co/u/jjdepaul)\
**Post date:** [February 9, 2016, 4:22pm UTC](https://discuss.elastic.co/t/how-to-pull-a-field-from-an-event-to-another-event/34235/3 "2016-02-09T16:22:49Z")

</div>

This probably comes to you too late to be of any use, but you can do it with class variables, if you're careful. There is a tradeoff: you will have to settle on only ONE worker in your logstash to avoid problems.

Here is a thread on how I did it:

> [@Keeping global variables in LS?!](https://discuss.elastic.co/t/keeping-global-variables-in-ls/39908/3):
>
> Well you didn't really wait too long for an answer slight_smile So you are treating each of these lines as unique events?

Good luck -

---

_[View the full topic](https://discuss.elastic.co/t/how-to-pull-a-field-from-an-event-to-another-event/34235)._
