# Refering to a specific \_type in Kibana

**URL:** https://discuss.elastic.co/t/refering-to-a-specific--type-in-kibana/55632
**Category:** Kibana
**Created:** [July 15, 2016, 3:12pm UTC](https://discuss.elastic.co/t/refering-to-a-specific--type-in-kibana/55632 "2016-07-15T15:12:32Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![arthur-y](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/arthur-y/32/7896_2.png) [@arthur-y](https://discuss.elastic.co/u/arthur-y)
#### Post date: [July 15, 2016, 3:12pm UTC](https://discuss.elastic.co/t/refering-to-a-specific--type-in-kibana/55632/1 "2016-07-15T15:12:32Z")

</div>

Hello all, hope you can help me.  
Imagine I have an Elasticsearch index **"sale-merged"** and 2 different types ( **\_traffic, \_bi-merged** ) within one index. Types store simillar data and the mappings are amost the same, just \_bi-merged has additional fields.

In ES I can run a query to specify from which \_type to retrieve documents:  
`{ "query": { "match": { "_type": "traffic" } } }`  
But at the stage when I configure the index to be used by default in Kibana, I see only documents that are stored under \_bi-merged type, but no documents in \_traffic type - [http://prntscr.com/btaahe](http://prntscr.com/btaahe)

The thing I want to achieve is to apply relation-database approach - where index is a database and \_type is a table.  
In the end, I need to be able to work with documents from both types in Kibana and Timelion

I would appreciate any feedback!

---

<div class="post-metadata">

### Author: ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)
#### Post date: [July 17, 2016, 7:28am UTC](https://discuss.elastic.co/t/refering-to-a-specific--type-in-kibana/55632/2 "2016-07-17T07:28:36Z")

</div>

I haven't seen this before, but does it persist if you refresh the index mappings in KB?

> [@arthur-y](#):
>
> The thing I want to achieve is to apply relation-database approach - where index is a database and \_type is a table.

Why, what is the point? ES is not a database and chances are you will run into [Index vs. Type | Elastic Blog](https://www.elastic.co/blog/index-vs-type)

---

<div class="post-metadata">

### Author: ![arthur-y](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/arthur-y/32/7896_2.png) [@arthur-y](https://discuss.elastic.co/u/arthur-y)
#### Post date: [July 18, 2016, 8:13am UTC](https://discuss.elastic.co/t/refering-to-a-specific--type-in-kibana/55632/3 "2016-07-18T08:13:26Z")

</div>

Well, we proceeded with perhaps not the best decision to build BI system on top of Elastic, and now this is more of a patching process.  
Actually, the issue can be resolved if when configuring the index in Kibana, I set the time field that exists in the mapping of both types - [http://prntscr.com/bu9kwq](http://prntscr.com/bu9kwq)  
Thus, I can use the filter '-type "traffic"' to exlude documents of an another type, but does not seem very consistent - [http://prntscr.com/bu9lax](http://prntscr.com/bu9lax).

Thanks for the article @warkolm, I guess in our use case, type use will be convinient.

---

<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, 1:46pm UTC](https://discuss.elastic.co/t/refering-to-a-specific--type-in-kibana/55632/4 "2017-07-06T13:46:07Z")

</div>


