How to use Date Range filter in Kibana?

Hi All,

I am trying to use kibana date filter range to plot a bar chart for my relevant data. I am unable to use the date filter for filtering out a particular range of data.

My date format in JSON is 2019-01-04T03:02:51.000Z. and Table format it's displayed as
Jan 4, 2019 @ 08:32:51.000.

Does anyone know to apply a date range filter? The official docs are of no use. TIA.

Regards,
Sujata

Hi Sujata and thanks for trying Kibana.

Curious what version of Kibana are you using?

I suspect you are getting the error [strict_date_optional_time||epoch_millis]:

1st you can apply a date filter by just using the Date Picker over near the top right... and click on Absolute and pick a date range.

Or if you want to use the Add Filter on the left hand side, the date needs to be in ISO Format (i.e. same as your JSON above) or MilliSeconds from the epoch, perhaps the docs should link to here instead.

What the strict_date_optional_time means is the Date is mandatory but the Time is optional

So valid formats would be

Date and Time
2019-08-11T14:00:00.000Z

or Date Only
2019-08-11

One word of caution, your date filter should be a subset of the Date Picker time range in the top right, if you date filter that is outside the time in the Date Picker you will get no results... in essence they are "ANDed" . If you clink on the Inspect link you will be the resulting request.

Hi @stephenb,

I am using Kibana 7.1.1. I don't want to filter data on the basis of timestamp. Instead, i want to filter it using the 'Open Date' field present in my index.

This is the data present in my kibana index.

Jan 3, 2019 @ 01:39:15.000 Universal_Id:SW453611 Open_Date:Jan 3, 2019 @ 07:09:15.000 Last_Update: Feb 18, 2019 @ 10:22:05.000

kibanaquery

Can u please help me with using the date filter using 'open date' field present in my kibana index?
Regards,
Sujata

Apologies I missed you were trying with a Bart Chart

but I think the Same Should Apply... Assuming OpenDate stored as a normal date field in Elasticsearch. You can check that looking the index pattern and making sure that is of type date.

Then any of the following should work
From 2019-08-11T13:40:12.762Z to 2019-08-13T13:40:12.762Z

Or from 2019-08-11 To 2019-08-12

Or From : now-1h To : now

https://www.elastic.co/guide/en/elasticsearch/reference/7.1/common-options.html#date-math