# Divide Should query into two parts and combine them with and logic

**URL:** <https://discuss.elastic.co/t/divide-should-query-into-two-parts-and-combine-them-with-and-logic/240120>\
**Category:** Elasticsearch\
**Created:** [July 7, 2020, 8:25am UTC](https://discuss.elastic.co/t/divide-should-query-into-two-parts-and-combine-them-with-and-logic/240120 "2020-07-07T08:25:21Z")\
**Posts on this page:** 1\
**Showing post:** 11

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [July 7, 2020, 12:41pm UTC](https://discuss.elastic.co/t/divide-should-query-into-two-parts-and-combine-them-with-and-logic/240120/11 "2020-07-07T12:41:07Z")

</div>

I meant what is described in the link I provided: [About the Elasticsearch category](https://discuss.elastic.co/t/about-the-elasticsearch-category/21)

> A typical script like this one can be copied and pasted in Kibana Dev Console by any reader. It will definitely help to play with your example and provide a fix for your script.

---

_[View the full topic](https://discuss.elastic.co/t/divide-should-query-into-two-parts-and-combine-them-with-and-logic/240120)._
