# Kibana: aggregation of timestamp field with date

**URL:** https://discuss.elastic.co/t/kibana-aggregation-of-timestamp-field-with-date/183823
**Category:** Kibana
**Created:** [June 1, 2019, 2:33pm UTC](https://discuss.elastic.co/t/kibana-aggregation-of-timestamp-field-with-date/183823 "2019-06-01T14:33:48Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![igour](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/igour/32/38679_2.png) [@igour](https://discuss.elastic.co/u/igour)
#### Post date: [June 1, 2019, 2:33pm UTC](https://discuss.elastic.co/t/kibana-aggregation-of-timestamp-field-with-date/183823/1 "2019-06-01T14:33:48Z")

</div>

Hi Team,  
I have a timestamp field which is coming from my log data source, the format is like:  
**"batchDate": "2019-05-30 09:11:08"**

But in visualization, I wanted to make the chart on each day basis from the same field as I do not have any other filed in my log data.

Currently, I have tried the same, on index pattern I changed the format from above to "DD MMM YY", in discovery I can see the expected format, but when I use the same batchDate in Kibana for x-axis I have multiple entries in x-axis for the same date.

I am thinking still, aggregation is happening at old format instead of just date one.

Please help on this, any kind of guidelines is welcome.

---

<div class="post-metadata">

### Author: ![nickpeihl](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nickpeihl/32/112622_2.png) [@nickpeihl](https://discuss.elastic.co/u/nickpeihl)
#### Post date: [June 3, 2019, 4:17pm UTC](https://discuss.elastic.co/t/kibana-aggregation-of-timestamp-field-with-date/183823/2 "2019-06-03T16:17:54Z")

</div>

If I understand correctly, you should not need to change the format of the date in the index pattern. You can use the Date Histogram aggregation in the visualization and specify the interval to use ("Daily" in your case).

 ![Screenshot_2019-06-03%20Kibana](https://us1.discourse-cdn.com/elastic/original/3X/4/5/4594d84575662bb35ee61dc650821092719606b2.png)

---

<div class="post-metadata">

### Author: ![igour](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/igour/32/38679_2.png) [@igour](https://discuss.elastic.co/u/igour)
#### Post date: [June 6, 2019, 10:23am UTC](https://discuss.elastic.co/t/kibana-aggregation-of-timestamp-field-with-date/183823/3 "2019-06-06T10:23:42Z")

</div>

Awesome, I was using it totally wrong.  
Thanks for the help.

---

<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: [July 4, 2019, 10:23am UTC](https://discuss.elastic.co/t/kibana-aggregation-of-timestamp-field-with-date/183823/4 "2019-07-04T10:23:50Z")

</div>

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