# What is the convention of underscores for?

**URL:** <https://discuss.elastic.co/t/what-is-the-convention-of-underscores-for/126161>\
**Category:** Elasticsearch\
**Created:** [March 29, 2018, 10:15pm UTC](https://discuss.elastic.co/t/what-is-the-convention-of-underscores-for/126161 "2018-03-29T22:15:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![arisbanach](https://avatars.discourse-cdn.com/v4/letter/a/f07891/32.png) [@arisbanach](https://discuss.elastic.co/u/arisbanach)\
**Post date:** [March 29, 2018, 10:15pm UTC](https://discuss.elastic.co/t/what-is-the-convention-of-underscores-for/126161/1 "2018-03-29T22:15:29Z")

</div>

Sometimes I see index types that are `doc` and other times I see `_doc`. Is there a conventional meaning for this in different contexts in ES?

---

<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:** [March 29, 2018, 10:27pm UTC](https://discuss.elastic.co/t/what-is-the-convention-of-underscores-for/126161/2 "2018-03-29T22:27:30Z")

</div>

They're usually reserved or system field names, eg `_id`.

In this instance it's just a (dual) standard till types no longer exist at all.

---

<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:** [April 26, 2018, 10:27pm UTC](https://discuss.elastic.co/t/what-is-the-convention-of-underscores-for/126161/3 "2018-04-26T22:27:49Z")

</div>

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