# V7.0.0 upgrade pain "\_type" now all doc, which field shoud I use instead?

**URL:** <https://discuss.elastic.co/t/v7-0-0-upgrade-pain-type-now-all-doc-which-field-shoud-i-use-instead/178637>\
**Category:** Elasticsearch\
**Created:** [April 26, 2019, 11:49am UTC](https://discuss.elastic.co/t/v7-0-0-upgrade-pain-type-now-all-doc-which-field-shoud-i-use-instead/178637 "2019-04-26T11:49:07Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![mortenb123](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mortenb123/32/37227_2.png) [@mortenb123](https://discuss.elastic.co/u/mortenb123)\
**Post date:** [April 26, 2019, 11:49am UTC](https://discuss.elastic.co/t/v7-0-0-upgrade-pain-type-now-all-doc-which-field-shoud-i-use-instead/178637/1 "2019-04-26T11:49:07Z")

</div>

I know removal of mapping types in v7: [https://www.elastic.co/guide/en/elasticsearch/reference/master/removal-of-types.html#\_schedule\_for\_removal\_of\_mapping\_types](https://www.elastic.co/guide/en/elasticsearch/reference/master/removal-of-types.html#_schedule_for_removal_of_mapping_types)

But \_type is now all \_doc  
We use "\_type" field very much as filter in kibana to look at data from a specific file.

I know I can use an index pattern with only the given file (cumpersome have 10K files)  
Or I can add a doctype field which holds the old mapping types.

But this has been a fundamental part of Kibana filtering as long as I've used it. So there must be a way of doing this without having to rewrite all my inserter-daemons.

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [April 29, 2019, 5:47am UTC](https://discuss.elastic.co/t/v7-0-0-upgrade-pain-type-now-all-doc-which-field-shoud-i-use-instead/178637/2 "2019-04-29T05:47:31Z")

</div>

> [@mortenb123](#):
>
> Or I can add a doctype field which holds the old mapping types.

This is the recommended approach and allows you to filter in Kibana.

---

<div class="post-metadata">

**Author:** ![mortenb123](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mortenb123/32/37227_2.png) [@mortenb123](https://discuss.elastic.co/u/mortenb123)\
**Post date:** [April 29, 2019, 7:12am UTC](https://discuss.elastic.co/t/v7-0-0-upgrade-pain-type-now-all-doc-which-field-shoud-i-use-instead/178637/3 "2019-04-29T07:12:01Z")

</div>

added doctype to all insert jobs and redeployed, but have some client, we havent touched in years with no CD or git access. Nice to test 🙂

---

<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:** [May 27, 2019, 7:12am UTC](https://discuss.elastic.co/t/v7-0-0-upgrade-pain-type-now-all-doc-which-field-shoud-i-use-instead/178637/4 "2019-05-27T07:12:04Z")

</div>

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