# How to set a range in Logs UI

**URL:** <https://discuss.elastic.co/t/how-to-set-a-range-in-logs-ui/164244>\
**Category:** Logs\
**Created:** [January 15, 2019, 6:19am UTC](https://discuss.elastic.co/t/how-to-set-a-range-in-logs-ui/164244 "2019-01-15T06:19:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![makefriend7](https://avatars.discourse-cdn.com/v4/letter/m/e274bd/32.png) [@makefriend7](https://discuss.elastic.co/u/makefriend7)\
**Post date:** [January 15, 2019, 6:19am UTC](https://discuss.elastic.co/t/how-to-set-a-range-in-logs-ui/164244/1 "2019-01-15T06:19:32Z")

</div>

In es we can do this  
GET \_search  
{  
"\_source":["message"],  
"query": {  
"range" : {  
"my.time": {  
"gte" : "20190113-09:15:57",  
"lte" : "20190114-10:15:57"  
}  
}  
}  
}

Is it possible in Logs UI?

---

<div class="post-metadata">

**Author:** ![simianhacker](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/simianhacker/32/3383_2.png) [@simianhacker](https://discuss.elastic.co/u/simianhacker)\
**Post date:** [January 17, 2019, 3:06pm UTC](https://discuss.elastic.co/t/how-to-set-a-range-in-logs-ui/164244/2 "2019-01-17T15:06:51Z")

</div>

It looks like you should be able to do that with a Kuery range expression that looks something like `range(bytes, gt=1000, lt=8000)`

Update: Strike that... looks like that's an old expression. How about `@timestamp <= 20190114-10:15:57 and @timestamp >= 20190113-09:15:57`. If that doesn't work you might have to convert the timestamps to Unix timestamps.

---

<div class="post-metadata">

**Author:** ![makefriend7](https://avatars.discourse-cdn.com/v4/letter/m/e274bd/32.png) [@makefriend7](https://discuss.elastic.co/u/makefriend7)\
**Post date:** [January 18, 2019, 5:14am UTC](https://discuss.elastic.co/t/how-to-set-a-range-in-logs-ui/164244/3 "2019-01-18T05:14:53Z")

</div>

@timestamp\>=2019-01-17 is OK.but @timestamp \>= 2019-01-17 10:15:03.842 is bad.  
I don't know how to type time in Logs UI (and if the @timestamp is a string \>= is also bad.)

---

<div class="post-metadata">

**Author:** ![weltenwort](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/weltenwort/32/53885_2.png) [@weltenwort](https://discuss.elastic.co/u/weltenwort)\
**Post date:** [January 18, 2019, 8:41am UTC](https://discuss.elastic.co/t/how-to-set-a-range-in-logs-ui/164244/4 "2019-01-18T08:41:41Z")

</div>

Using strings formatted in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) for timestamps should work, e.g. `@timestamp >= "2019-01-17T10:15:03.842Z"` for a date in UTC.

---

<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:** [February 15, 2019, 8:41am UTC](https://discuss.elastic.co/t/how-to-set-a-range-in-logs-ui/164244/5 "2019-02-15T08:41:45Z")

</div>

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