# Gte or null

**URL:** <https://discuss.elastic.co/t/gte-or-null/74110>\
**Category:** Elasticsearch\
**Created:** [February 6, 2017, 7:02pm UTC](https://discuss.elastic.co/t/gte-or-null/74110 "2017-02-06T19:02:31Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![fix2015](https://avatars.discourse-cdn.com/v4/letter/f/aca169/32.png) [@fix2015](https://discuss.elastic.co/u/fix2015)\
**Post date:** [February 6, 2017, 7:02pm UTC](https://discuss.elastic.co/t/gte-or-null/74110/1 "2017-02-06T19:02:31Z")

</div>

hey guys, maybe someone had same pb as i, i need write request to project that have availiable\_date more than today and availiable\_date that equal null.

> {  
> query:{  
> bool:{  
> filter:{  
> must:{  
> range:{  
> avalible\_to:{  
> lte:"2017-02-06T20:57:22+02:00"  
> }  
> }  
> }  
> }  
> }  
> }  
> }

---

<div class="post-metadata">

**Author:** ![spinscale](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/spinscale/32/25011_2.png) [@spinscale](https://discuss.elastic.co/u/spinscale)\
**Post date:** [February 7, 2017, 8:17am UTC](https://discuss.elastic.co/t/gte-or-null/74110/2 "2017-02-07T08:17:21Z")

</div>

Hey,

what does `equal null` mean in this context? If you index a JSON field with the value `null`, it is dropped by default, unless you configure [null\_value](https://www.elastic.co/guide/en/elasticsearch/reference/5.2/null-value.html) in your mapping. If you need an open bound, just omit the `gte` part of your query.

--Alex

---

<div class="post-metadata">

**Author:** ![fix2015](https://avatars.discourse-cdn.com/v4/letter/f/aca169/32.png) [@fix2015](https://discuss.elastic.co/u/fix2015)\
**Post date:** [February 7, 2017, 8:29am UTC](https://discuss.elastic.co/t/gte-or-null/74110/3 "2017-02-07T08:29:27Z")

</div>

yep i want have result of data that have defaul null or gte than today

---

<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:** [March 7, 2017, 8:29am UTC](https://discuss.elastic.co/t/gte-or-null/74110/4 "2017-03-07T08:29:44Z")

</div>

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