0
votes

I'm getting the below error while trying to create a stored procedure using Azure documentDb .NET SDK. The script content size is 430KB.

Message: {"Errors":["The input Body length is invalid. Ensure to provide a script of size lesser than '102400' characters.","The request payload is invalid. Ensure to provide a valid request payload."]}

I could see the below from Azure DocumentDB limits article

Maximum request size of stored procedure, trigger and UDF: 512KB

Could anyone please explain below.

  1. Is this the stored procedure script body size?
  2. If it is then what does this error mean?
1
I'm looking into this, but I gotta ask: How does one construct a 430K stored procedure??? - David Makogon
@David: I meant the Javascript function body size which would be the stored procedure definition body in the DocumentDB - Sivaram K
430KB for a stored procedure is rather large. Did you know that the entire JSQuery (minified) is only 84KB. - Ryan CrawCour
When creating a stored procedure, it is a good idea to minify the script. You will be able to save a much bigger script if it has been minified. - Ryan CrawCour
@Ram if you would like to reach out to us to discuss this, and why you need such a large script, then please reach out to us via askdocdb.com - Ryan CrawCour

1 Answers

2
votes

Yes, this refers to the size of the script body. The max size for a stored procedure body is 100KB.

I will make a note to address the documentation accordingly.