# Add term filter query

**URL:** <https://discuss.elastic.co/t/add-term-filter-query/281012>\
**Category:** Elasticsearch\
**Created:** [August 11, 2021, 8:17am UTC](https://discuss.elastic.co/t/add-term-filter-query/281012 "2021-08-11T08:17:07Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jose\_Manuel\_Tirado](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jose_manuel_tirado/32/84882_2.png) [@Jose\_Manuel\_Tirado](https://discuss.elastic.co/u/Jose_Manuel_Tirado)\
**Post date:** [August 11, 2021, 8:17am UTC](https://discuss.elastic.co/t/add-term-filter-query/281012/1 "2021-08-11T08:17:07Z")

</div>

HI:

I am using this query to fetch elastic data through python connector:

```auto
{
   "query":
                   {"range": {"nuanceTimestamp": {"gte": f"{date1}T{str(hour_in).zfill(2)}:00:00Z",
                                                "lte": f"{date1}T{str(hour_in + 2).zfill(2)}:00:00Z"}}},
                    "_source": {
                                "includes": ['nuanceTimestamp', 'EVNT', 'CHAN', 'UCID', 'CALLID', 'sourceNuance', 
                                     'WVNMurl', 'ANI', 'SPOK', 'RSLT', 'CONF', 'SWIrcst.GRNM'],
                                 "excludes": []
            }
        }

```

I want to add one more filter to the query so that it only brings me those data that have the SWIrcnd value in the EVNT field.

How could I add this new filter to the previous query?

I've been trying for a while and I can't.

Thanks and regards

---

<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:** [September 8, 2021, 8:17am UTC](https://discuss.elastic.co/t/add-term-filter-query/281012/2 "2021-09-08T08:17:21Z")

</div>

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