# Set Unlimited length for Elastic Search json Query

**URL:** https://discuss.elastic.co/t/set-unlimited-length-for-elastic-search-json-query/121046
**Category:** Elasticsearch
**Created:** [February 22, 2018, 12:31pm UTC](https://discuss.elastic.co/t/set-unlimited-length-for-elastic-search-json-query/121046 "2018-02-22T12:31:34Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Mayank\_Garg](https://avatars.discourse-cdn.com/v4/letter/m/f05b48/32.png) [@Mayank\_Garg](https://discuss.elastic.co/u/Mayank_Garg)
#### Post date: [February 22, 2018, 12:31pm UTC](https://discuss.elastic.co/t/set-unlimited-length-for-elastic-search-json-query/121046/1 "2018-02-22T12:31:34Z")

</div>

I am creating an elasticSearch-5.6.x query but after 10003 characters (Byte) count, I am unable to append more parameters into my query. Please help to set the query length to a specific number or making it unlimited in java.

The query is in JSON format. It's about the size of query, NOT RESPONSE. We are not hitting max clause count, set default at 1024.

BoolQueryBuilder matchQuery = QueryBuilders.boolQuery();  
matchQuery.should(QueryBuilders.matchQuery(//some code));

matchQuery wont add once it has characters count =10003.

---

<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: [March 22, 2018, 12:31pm UTC](https://discuss.elastic.co/t/set-unlimited-length-for-elastic-search-json-query/121046/2 "2018-03-22T12:31:47Z")

</div>

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