# Querying Multiple Indexes (of different field mappings) causing Failed Shards Exception

**URL:** https://discuss.elastic.co/t/querying-multiple-indexes-of-different-field-mappings-causing-failed-shards-exception/128296
**Category:** Kibana
**Created:** [April 17, 2018, 6:51am UTC](https://discuss.elastic.co/t/querying-multiple-indexes-of-different-field-mappings-causing-failed-shards-exception/128296 "2018-04-17T06:51:01Z")
**Posts on this page:** 1
**Showing post:** 3

<div class="post-metadata">

### Author: ![waleed\_ali](https://avatars.discourse-cdn.com/v4/letter/w/ebca7d/32.png) [@waleed\_ali](https://discuss.elastic.co/u/waleed_ali)
#### Post date: [April 19, 2018, 3:02pm UTC](https://discuss.elastic.co/t/querying-multiple-indexes-of-different-field-mappings-causing-failed-shards-exception/128296/3 "2018-04-19T15:02:33Z")

</div>

Hello,

Thank you, Tim, for taking some time out and looking into my problem. I was following the first approach that you have mentioned but our use case demands to show the live data over a single geographical map.  
I understand that ES is a NoSQL datastore and doesn't support JOINS. I have managed to find a workaround however, following jureken answer in this [post](https://discuss.elastic.co/t/joins-in-kibana-to-fetch-data-from-multiple-indexes/31893/5). Now I am appending each packet of my live data with location information.  
Still, I wanted to ask you two things:

1. Is it the right approach?
2. Right now I am doing this programmatically (have written a script to append location information in each packet and then dump it in Logstash and ES). How can I do this thing
  - take ID from each packet, search ES index containing location information and fetch the document with this ID,
  - add the fetched document to the packet  
in Logstash Conf, as Jureken has mentioned?

---

_[View the full topic](https://discuss.elastic.co/t/querying-multiple-indexes-of-different-field-mappings-causing-failed-shards-exception/128296)._
