# How to write using Kibana search bar

**URL:** https://discuss.elastic.co/t/how-to-write-using-kibana-search-bar/165959
**Category:** Kibana
**Created:** [January 28, 2019, 8:48am UTC](https://discuss.elastic.co/t/how-to-write-using-kibana-search-bar/165959 "2019-01-28T08:48:41Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![a86236df74eecab0f8a3](https://avatars.discourse-cdn.com/v4/letter/a/e480ec/32.png) [@a86236df74eecab0f8a3](https://discuss.elastic.co/u/a86236df74eecab0f8a3)
#### Post date: [January 28, 2019, 8:48am UTC](https://discuss.elastic.co/t/how-to-write-using-kibana-search-bar/165959/1 "2019-01-28T08:48:41Z")

</div>

Hi Experts,

 ![problem](https://us1.discourse-cdn.com/elastic/original/3X/b/2/b2a32d6d5ccecc2fcb5ff027489353d99e24b0ea.png)

This is the data between October and December of something.  
I want to find data that have accessed by October but never accessed in December.  
If I do what I think, the result should show b only. But it did not work well.

so I wrote in search bar like  
@timestamp:[\* TO 2018-10-31T23:59:59.999Z] AND NOT @timestamp:[2018-12-01T00:00:00.000Z TO now]

 ![problem_result](https://us1.discourse-cdn.com/elastic/original/3X/1/4/14e31df981e5e0dbad008963c162289742862673.png)

This is result.

What's the problem?

---

<div class="post-metadata">

### Author: ![Larry\_Gregory](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/larry_gregory/32/34969_2.png) [@Larry\_Gregory](https://discuss.elastic.co/u/Larry_Gregory)
#### Post date: [January 28, 2019, 3:42pm UTC](https://discuss.elastic.co/t/how-to-write-using-kibana-search-bar/165959/2 "2019-01-28T15:42:50Z")

</div>

Hey @a86236df74eecab0f8a3,

I don't think this is currently possible as-is. What you could do is write a script to enrich your existing data (perhaps using the re-index API), and add a new field which indicates whether or not the entity was accessed between a specific time range.

---

<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 25, 2019, 3:50pm UTC](https://discuss.elastic.co/t/how-to-write-using-kibana-search-bar/165959/3 "2019-02-25T15:50:38Z")

</div>

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