# Creating multiple query\_string

**URL:** <https://discuss.elastic.co/t/creating-multiple-query-string/138851>\
**Category:** Elasticsearch\
**Created:** [July 6, 2018, 8:34am UTC](https://discuss.elastic.co/t/creating-multiple-query-string/138851 "2018-07-06T08:34:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![shubham\_kumar1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/shubham_kumar1/32/22084_2.png) [@shubham\_kumar1](https://discuss.elastic.co/u/shubham_kumar1)\
**Post date:** [July 6, 2018, 8:34am UTC](https://discuss.elastic.co/t/creating-multiple-query-string/138851/1 "2018-07-06T08:34:40Z")

</div>

Hi,  
I want query data form elasticsearch based on some value of the string, i wrote following query for that.

```
GET _search
{
  "query": {
    "bool": {
      "filter":{
        "bool":{
          "should": [
        {
          "query_string": {
            "default_field": "log_mesage",
            "query": "UE CTX REL-RLF", 
            "default_operator": "AND"
          }
        },
        {
          "query_string": {
            "default_field": "log_message",
            "query": "uecc_s1ap_build_and_send_enb_ue_ctx_release_req AND S_TMSI.MMEC"
          }
        }
      ], "minimum_should_match": 1
    }
        }
      }
  }
}

```

When i am running this query, i am only getting result for the 2nd query i.e "query": "uecc\_s1ap\_build\_and\_send\_enb\_ue\_ctx\_release\_req AND S\_TMSI.MMEC" .

---

<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 6, 2018, 10:03am UTC](https://discuss.elastic.co/t/creating-multiple-query-string/138851/2 "2018-07-06T10:03:21Z")

</div>

What does a document look like? What is the mapping?

Could you provide a full recreation script as described in [About the Elasticsearch category](https://discuss.elastic.co/t/about-the-elasticsearch-category/21). It will help to better understand what you are doing. Please, try to keep the example as simple as possible.

A full reproduction script will help readers to understand, reproduce and if needed fix your problem. It will also most likely help to get a faster answer.

---

<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:** [August 3, 2018, 10:03am UTC](https://discuss.elastic.co/t/creating-multiple-query-string/138851/3 "2018-08-03T10:03:28Z")

</div>

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