# How to query for most recent timestamp and filter query

**URL:** <https://discuss.elastic.co/t/how-to-query-for-most-recent-timestamp-and-filter-query/166539>\
**Category:** Logstash\
**Created:** [January 31, 2019, 11:16am UTC](https://discuss.elastic.co/t/how-to-query-for-most-recent-timestamp-and-filter-query/166539 "2019-01-31T11:16:05Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![manickalai](https://avatars.discourse-cdn.com/v4/letter/m/94ad74/32.png) [@manickalai](https://discuss.elastic.co/u/manickalai)\
**Post date:** [January 31, 2019, 11:16am UTC](https://discuss.elastic.co/t/how-to-query-for-most-recent-timestamp-and-filter-query/166539/1 "2019-01-31T11:16:06Z")

</div>

How do I query for the timestamp of the most recent entry for a specific type filter like  
@applicationName:  
@HOSTNAME:  
@appname:  
@timestamp:

sample logs

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/7/c/7c3e89553a313aa203bb8fe515d3902df15f1b90.png)

Kindly help me to write right query format?

---

<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:** [February 28, 2019, 11:16am UTC](https://discuss.elastic.co/t/how-to-query-for-most-recent-timestamp-and-filter-query/166539/2 "2019-02-28T11:16:10Z")

</div>

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