# MultiIndex filter and search

**URL:** <https://discuss.elastic.co/t/multiindex-filter-and-search/106066>\
**Category:** Elasticsearch\
**Created:** [November 1, 2017, 4:59pm UTC](https://discuss.elastic.co/t/multiindex-filter-and-search/106066 "2017-11-01T16:59:04Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![samdash](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/samdash/32/21628_2.png) [@samdash](https://discuss.elastic.co/u/samdash)\
**Post date:** [November 1, 2017, 4:59pm UTC](https://discuss.elastic.co/t/multiindex-filter-and-search/106066/1 "2017-11-01T16:59:04Z")

</div>

Hi ,

I have 2 indexes **com** and **article** , which contain documents which are different and only thing that is common between the documents is \_id , i need a filter and search Query from these 2 indexes , please let me know how to approach on this . First i need to Filter on COM index by TAGID and do search "text" from articleIndex  
Filter by TAGID will return me \_id ABC1234 and search for "Airtel iPhone" should return the same document however when i search for " something not in the document" it should not return ABC1234 article , please let me know how to go about this.

com index has following documents

```
{
  "_index": "com",
  "_type": "com",
  "_id": "ABC1234",
   "_score": 1,
    "locale": "en_US",
    "tags": [
      {
        "tagid": "TAG_A"
       },
      {
        "tagid": "TAG_B"
       }
    ]
  }
}

```

and have another index called article which has following doument's

```
{
  "_index": "article",
  "_type": "article",
  "_id": "ABC1234",
  "_version": 1,
  "_score": 1,
  "content": {
    "main": {
      "summary": "<p>WhatsApp Message Delete Feature, Pixel 2 on Sale in India, **Airtel iPhone** X Offer, and More: Your 360 Daily</p> ",
      "title": "The feature will work only if the recipient has the latest version of the app too, and messages can be deleted up to 7 minutes after they are sent"
    },
    "sections": [
      {
        "level": "1",
        "sections": [
          
        ],
        "text": "<p>To use the message delete feature, just select the message you want to delete, and tap on the trash icon on the screen; here you will see ' **Delete for Me**' and 'Delete for Everyone'. While the former only deletes the message on your phone, the latter removes it from the recipients' devices as well:</p>",
        "title": "Airtel is not taking iPhone X pre-orders and will go straight to the sale on Friday"
      }
    ]
  },
  "locale": "en_US"
}
```

---

<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:** [November 29, 2017, 4:59pm UTC](https://discuss.elastic.co/t/multiindex-filter-and-search/106066/2 "2017-11-29T16:59:19Z")

</div>

Closed on November 29, 2017, 4:59pm UTC

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