# ES timestamp index not working while creating index

**URL:** <https://discuss.elastic.co/t/es-timestamp-index-not-working-while-creating-index/134104>\
**Category:** Elasticsearch\
**Created:** [May 31, 2018, 7:47pm UTC](https://discuss.elastic.co/t/es-timestamp-index-not-working-while-creating-index/134104 "2018-05-31T19:47:29Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![jscubida](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jscubida/32/24214_2.png) [@jscubida](https://discuss.elastic.co/u/jscubida)\
**Post date:** [June 1, 2018, 8:35pm UTC](https://discuss.elastic.co/t/es-timestamp-index-not-working-while-creating-index/134104/4 "2018-06-01T20:35:59Z")

</div>

I believe Logstash is inserting the current time based on [this answer](https://discuss.elastic.co/t/add-field-timestamp-with-current-time/59862). Since your timestamp field is a string upon being input into Logstash, I think you'll have to format the string and convert it into a date. [This](https://discuss.elastic.co/t/conver-string-to-date-or-replace-timestamp-solved/32957) should be of assistance.

---

_[View the full topic](https://discuss.elastic.co/t/es-timestamp-index-not-working-while-creating-index/134104)._
