1

I am using cosmos db , sql api. I want to know what is the maximum character limit for queries.

Below post mentions > 30 kb for Mongo API : https://feedback.azure.com/forums/263030-azure-cosmos-db/suggestions/32665819-increase-query-maximum-character-limit-for-cosmo-m

Is there a similar limit for SQL API as well ?

Thanks !

EDIT 1 : I am testing this on the cosmos db emulator on my laptop.

1 Answer 1

1

Max query size is 256 KB. You can find this and other service quota and limits here.

Thanks.

Sign up to request clarification or add additional context in comments.

2 Comments

Thanks Mark, but how do i calculate it for my query ? I am doing a findByVariableIn() in my Java's JPA repository and passing a list of 3000 Strings of 4 characters each , which by UTF-8 encoding becomes 4 bytes each, so totals to 3000x4 = 12 kb. I get a "gone exception" in this case. It works fine if im passing only 2000 strings. I am using cosmos DB emulator .
The linked page states the current limit to be 512KB

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.