# Join data in two different logs

**URL:** <https://discuss.elastic.co/t/join-data-in-two-different-logs/45608>\
**Category:** Logstash\
**Created:** [March 28, 2016, 4:28pm UTC](https://discuss.elastic.co/t/join-data-in-two-different-logs/45608 "2016-03-28T16:28:59Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![vilas](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vilas/32/613_2.png) [@vilas](https://discuss.elastic.co/u/vilas)\
**Post date:** [March 28, 2016, 4:28pm UTC](https://discuss.elastic.co/t/join-data-in-two-different-logs/45608/1 "2016-03-28T16:28:59Z")

</div>

Hi,

I have two logs files on remote server. Both those log files have a key that I can join the two log files on.  
I want this data to be in elasticsearch as a single document. Can we do this somehow?

Thanks.

---

<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:** [March 29, 2016, 5:48am UTC](https://discuss.elastic.co/t/join-data-in-two-different-logs/45608/2 "2016-03-29T05:48:24Z")

</div>

Logstash isn't terribly good at this , but maybe the collate filter can help.

---

<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, 5:05am UTC](https://discuss.elastic.co/t/join-data-in-two-different-logs/45608/3 "2017-07-06T05:05:01Z")

</div>


