# How to fetch the last updated time of the document in ES 5.0

**URL:** https://discuss.elastic.co/t/how-to-fetch-the-last-updated-time-of-the-document-in-es-5-0/70517
**Category:** Elasticsearch
**Created:** [January 4, 2017, 6:47am UTC](https://discuss.elastic.co/t/how-to-fetch-the-last-updated-time-of-the-document-in-es-5-0/70517 "2017-01-04T06:47:49Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Renuka\_Aradhya](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/renuka_aradhya/32/14294_2.png) [@Renuka\_Aradhya](https://discuss.elastic.co/u/Renuka_Aradhya)
#### Post date: [January 4, 2017, 6:47am UTC](https://discuss.elastic.co/t/how-to-fetch-the-last-updated-time-of-the-document-in-es-5-0/70517/1 "2017-01-04T06:47:49Z")

</div>

This is in 5.0.0 version of ES and using Java APIs.

I am trying to fetch the last updated time and version of the document in ES. I am able to fetch the version but not the last updated time stamp of the document.

Please help me to do this.

---

<div class="post-metadata">

### Author: ![nik9000](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nik9000/32/44947_2.png) [@nik9000](https://discuss.elastic.co/u/nik9000)
#### Post date: [January 4, 2017, 1:04pm UTC](https://discuss.elastic.co/t/how-to-fetch-the-last-updated-time-of-the-document-in-es-5-0/70517/2 "2017-01-04T13:04:22Z")

</div>

Have a look at the ingest feature. There is a way to set it up to add the  
last modified timestamp to the document. Otherwise elasticsearch doesn't  
store such a timestamp.

---

<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: [January 7, 2017, 1:04pm UTC](https://discuss.elastic.co/t/how-to-fetch-the-last-updated-time-of-the-document-in-es-5-0/70517/3 "2017-01-07T13:04:23Z")

</div>

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