# Question on multiple date fields in an event and time range

**URL:** https://discuss.elastic.co/t/question-on-multiple-date-fields-in-an-event-and-time-range/176090
**Category:** Kibana
**Created:** [April 9, 2019, 7:13pm UTC](https://discuss.elastic.co/t/question-on-multiple-date-fields-in-an-event-and-time-range/176090 "2019-04-09T19:13:51Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![Sudhakar\_Madeti](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sudhakar_madeti/32/42718_2.png) [@Sudhakar\_Madeti](https://discuss.elastic.co/u/Sudhakar_Madeti)
#### Post date: [April 9, 2019, 7:13pm UTC](https://discuss.elastic.co/t/question-on-multiple-date-fields-in-an-event-and-time-range/176090/1 "2019-04-09T19:13:51Z")

</div>

I am trying to push all our team's tickets into ELK. The tickets have 5 date fields and I have 2 questions in this regard. I have all the data in the same index. The 5 different date fields:

Planned\_Start\_Time  
Planned\_End\_Time  
Actual\_Start\_Time  
Actual\_End\_Time  
Updated\_Time

Question 1: I want the event to be displayed for each of these 5 time instances when any of these are falling in the timepicker range in Kibana. Do I need to insert the same event multiple (5) times and associating each datefield with @Timestamp ? My time series chart is created with Date Histogram with @Timestamp.

Question 2: There are some events which span over days. Let us say that the start\_date and end\_date are 6hrs apart - for example from 06:00 till 12:00. When I am searching for any events ongoing between 08:00 and 10:00, I do not find this event. Anyway to accomplish this ?

Thanks in advance for your support

Best regards  
Sudhakar

---

<div class="post-metadata">

### Author: ![Marius\_Dragomir](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/marius_dragomir/32/42087_2.png) [@Marius\_Dragomir](https://discuss.elastic.co/u/Marius_Dragomir)
#### Post date: [April 12, 2019, 10:05am UTC](https://discuss.elastic.co/t/question-on-multiple-date-fields-in-an-event-and-time-range/176090/2 "2019-04-12T10:05:23Z")

</div>

Q1:  
Yeah, you'll have to have the event ingested 5 times, you could do something like this:  
{  
name: event1,  
action: Planned\_Start  
timestamp: time  
}  
and so on. This way you can display all 5 datesfields on the chart.

Q2. Other than having events piped in at a specific time interval that says ongoing or not, you won't be able to accomplish that in ES from what I can tell.

---

<div class="post-metadata">

### Author: ![Marius\_Dragomir](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/marius_dragomir/32/42087_2.png) [@Marius\_Dragomir](https://discuss.elastic.co/u/Marius_Dragomir)
#### Post date: [April 12, 2019, 10:09am UTC](https://discuss.elastic.co/t/question-on-multiple-date-fields-in-an-event-and-time-range/176090/3 "2019-04-12T10:09:53Z")

</div>

Update: i think you could use Canvas and the new SQL-like expression editor to achieve what you want from Q2. It will take a while to get into it, but it pretty much can solve any data problem, so it's a good feature to learn: [https://www.elastic.co/guide/en/kibana/current/canvas.html](https://www.elastic.co/guide/en/kibana/current/canvas.html)

---

<div class="post-metadata">

### Author: ![Sudhakar\_Madeti](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sudhakar_madeti/32/42718_2.png) [@Sudhakar\_Madeti](https://discuss.elastic.co/u/Sudhakar_Madeti)
#### Post date: [April 13, 2019, 10:26am UTC](https://discuss.elastic.co/t/question-on-multiple-date-fields-in-an-event-and-time-range/176090/4 "2019-04-13T10:26:53Z")

</div>

Thanks Marius. So, I have to insert the event multiple times.

---

<div class="post-metadata">

### Author: ![Sudhakar\_Madeti](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sudhakar_madeti/32/42718_2.png) [@Sudhakar\_Madeti](https://discuss.elastic.co/u/Sudhakar_Madeti)
#### Post date: [April 13, 2019, 10:28am UTC](https://discuss.elastic.co/t/question-on-multiple-date-fields-in-an-event-and-time-range/176090/5 "2019-04-13T10:28:22Z")

</div>

Thanks for the tip. Will look into it.

Best regards

---

<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: [May 11, 2019, 10:29am UTC](https://discuss.elastic.co/t/question-on-multiple-date-fields-in-an-event-and-time-range/176090/6 "2019-05-11T10:29:42Z")

</div>

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