# Date comparison in Logstash/Kibana

**URL:** <https://discuss.elastic.co/t/date-comparison-in-logstash-kibana/160178>\
**Category:** Logstash\
**Created:** [December 10, 2018, 1:10pm UTC](https://discuss.elastic.co/t/date-comparison-in-logstash-kibana/160178 "2018-12-10T13:10:38Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vivek\_Sharma](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vivek_sharma/32/46948_2.png) [@Vivek\_Sharma](https://discuss.elastic.co/u/Vivek_Sharma)\
**Post date:** [December 10, 2018, 1:10pm UTC](https://discuss.elastic.co/t/date-comparison-in-logstash-kibana/160178/1 "2018-12-10T13:10:38Z")

</div>

Hi

I am receiving an XML file as input where I have a date field in format CYYMMDD format (eg: 1181210).

I need to perform a logic that if this date is less than system date then I have to show this as error.

Can anyone please help on the logic and syntax that I need to use in order to achieve this.

System date when fetched in logstash is in different format than this.

Thanks  
Vivek Sharma

---

<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, 2019, 1:10pm UTC](https://discuss.elastic.co/t/date-comparison-in-logstash-kibana/160178/2 "2019-01-07T13:10:49Z")

</div>

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