# Use field value of one querry to another

**URL:** <https://discuss.elastic.co/t/use-field-value-of-one-querry-to-another/142877>\
**Category:** Elasticsearch\
**Created:** [August 3, 2018, 9:07am UTC](https://discuss.elastic.co/t/use-field-value-of-one-querry-to-another/142877 "2018-08-03T09:07:07Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![MarcusCaepio](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/marcuscaepio/32/32458_2.png) [@MarcusCaepio](https://discuss.elastic.co/u/MarcusCaepio)\
**Post date:** [August 3, 2018, 9:07am UTC](https://discuss.elastic.co/t/use-field-value-of-one-querry-to-another/142877/1 "2018-08-03T09:07:08Z")

</div>

Hi all,  
I have several documents with several fields. I need to know how to querry the follwing situation in discovery (kibana)

Doc1:  
field1, field2

Doc2:  
field2, field3

"Show (and save?) me in Doc1 all "field2" where field1 = "X" and then show me in Doc2 all fields where field2 and field3 = "Y"

So I basically need sth like a join(?)  
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:** [August 31, 2018, 9:07am UTC](https://discuss.elastic.co/t/use-field-value-of-one-querry-to-another/142877/2 "2018-08-31T09:07:21Z")

</div>

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