# Filter data in interval or based on a specific field

**URL:** https://discuss.elastic.co/t/filter-data-in-interval-or-based-on-a-specific-field/308351
**Category:** Kibana
**Created:** [June 28, 2022, 11:40am UTC](https://discuss.elastic.co/t/filter-data-in-interval-or-based-on-a-specific-field/308351 "2022-06-28T11:40:56Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Alice\_Ionescu](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@Alice\_Ionescu](https://discuss.elastic.co/u/Alice_Ionescu)
#### Post date: [June 28, 2022, 11:40am UTC](https://discuss.elastic.co/t/filter-data-in-interval-or-based-on-a-specific-field/308351/1 "2022-06-28T11:40:56Z")

</div>

Hello,

I would like to filter data based on an interval **or** based on a specific field.

For example I have a filter for begin date, one for end date and one for a specific date

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/a/9/a90d877ef6a4551633956a77511186353e78b54a.png)

Begin date filter looks like this

![image](https://us1.discourse-cdn.com/elastic/original/3X/b/0/b09efc90faea238025fc1a17ec0451722bbc756a.png)

I would like to have one filter that joins the interval and the specific date with OR. To have the records valid in the interval **or** be 01.01.1970

Do you have any suggestions?

Thanks!

---

<div class="post-metadata">

### Author: ![JLeysens](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jleysens/32/67404_2.png) [@JLeysens](https://discuss.elastic.co/u/JLeysens)
#### Post date: [June 29, 2022, 9:02am UTC](https://discuss.elastic.co/t/filter-data-in-interval-or-based-on-a-specific-field/308351/2 "2022-06-29T09:02:35Z")

</div>

Hi @Alice_Ionescu !

If I'm understanding what you are trying to do correctly, I think the way to do this would be with a query for the non-overlapping time ranges.

 ![Screenshot 2022-06-29 at 10.59.20](https://us1.discourse-cdn.com/elastic/original/3X/7/1/71c909806508c3edeb709e3a9a45c969073e8ddf.png)

Filters are not ORed together.

---

<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 27, 2022, 9:03am UTC](https://discuss.elastic.co/t/filter-data-in-interval-or-based-on-a-specific-field/308351/3 "2022-07-27T09:03:27Z")

</div>

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