# For search query ,giving logs without searching the content using nesed query

**URL:** <https://discuss.elastic.co/t/for-search-query-giving-logs-without-searching-the-content-using-nesed-query/230150>\
**Category:** Elasticsearch\
**Created:** [April 28, 2020, 11:30am UTC](https://discuss.elastic.co/t/for-search-query-giving-logs-without-searching-the-content-using-nesed-query/230150 "2020-04-28T11:30:16Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![vinay123](https://avatars.discourse-cdn.com/v4/letter/v/a9a28c/32.png) [@vinay123](https://discuss.elastic.co/u/vinay123)\
**Post date:** [April 28, 2020, 11:30am UTC](https://discuss.elastic.co/t/for-search-query-giving-logs-without-searching-the-content-using-nesed-query/230150/1 "2020-04-28T11:30:16Z")

</div>

- Hello All,

- I have nested Json which is 1000 lines, i am writing a nested match query to find matching content , but i am getting logs as :

- `

- 
  1. {searchType=QUERY\_THEN\_FETCH, indices=[jsonfile], indicesOptions=IndicesOptions[ignore\_unavailable=false, allow\_no\_indices=true, expand\_wildcards\_open=true, expand\_wildcards\_closed=false, allow\_aliases\_to\_multiple\_indices=true, forbid\_closed\_indices=true, ignore\_aliases=false, ignore\_throttled=true], types=, routing='null', preference='null', requestCache=null, scroll=null, maxConcurrentShardRequests=0, batchedReduceSize=512, preFilterShardSize=128, allowPartialSearchResults=null, localClusterAlias=null, getOrCreateAbsoluteStartMillis=-1, source={}}

- I am using nested query as :

- SearchRequest request = Requests.searchRequest("jsonfile")

- 

```
                .source(SearchSourceBuilder.searchSource().query(QueryBuilders.boolQuery()

```

- 

```
                        .should(QueryBuilders.matchQuery("name", "vinay"))

```

- 

```
                        .should(QueryBuilders.matchQuery("location", "india"))

```

- 

```
                        .should(QueryBuilders.matchQuery("address", "hyd"))

```

- 

```
                        .minimumShouldMatch(1)));

```

- for this query i am getting logs as

- {searchType=QUERY\_THEN\_FETCH, indices=[jsonfile], indicesOptions=IndicesOptions[ignore\_unavailable=false, allow\_no\_indices=true, expand\_wildcards\_open=true, expand\_wildcards\_closed=false, allow\_aliases\_to\_multiple\_indices=true, forbid\_closed\_indices=true, ignore\_aliases=false, ignore\_throttled=true], types=, routing='null', preference='null', requestCache=null, scroll=null, maxConcurrentShardRequests=0, batchedReduceSize=512, preFilterShardSize=128, allowPartialSearchResults=null, localClusterAlias=null, getOrCreateAbsoluteStartMillis=-1, source={"query":{"bool":{"should":[{"match":{"name":{"query":"vinay","operator":"OR","prefix\_length":0,"max\_expansions":50,"fuzzy\_transpositions":true,"lenient":false,"zero\_terms\_query":"NONE","auto\_generate\_synonyms\_phrase\_query":true,"boost":1.0}}},{"match":{"location":{"query":"india","operator":"OR","prefix\_length":0,"max\_expansions":50,"fuzzy\_transpositions":true,"lenient":false,"zero\_terms\_query":"NONE","auto\_generate\_synonyms\_phrase\_query":true,"boost":1.0}}},{"match":{"address":{"query":"hyd","operator":"OR","prefix\_length":0,"max\_expansions":50,"fuzzy\_transpositions":true,"lenient":false,"zero\_terms\_query":"NONE","auto\_generate\_synonyms\_phrase\_query":true,"boost":1.0}}}],"adjust\_pure\_negative":true,"minimum\_should\_match":"1","boost":1.0}}}}

- any suggestion.`Preformatted text`

- `

---

<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:** [May 26, 2020, 11:30am UTC](https://discuss.elastic.co/t/for-search-query-giving-logs-without-searching-the-content-using-nesed-query/230150/2 "2020-05-26T11:30:20Z")

</div>

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