GlideSysAttachment getContentstream not working for more than 5 mb attachments in Scoped Application

Manisha17
Tera Contributor

Hi,

We are using using below piece of code for reading excel attachment, its working for small attachments but not working for large attachment ( it seems more than 5mb). Global property attachment max size is set to 20mb.

var parser = new sn_impex.GlideExcelParser();
var attachment = new GlideSysAttachment();
var attachmentStream = attachment.getContentStream(sys_id); //sys_id of attachment

parser.setSheetName("Template"); 
parser.setHeaderRowNumber(-1);
parser.parse(attachmentStream);

while (parser.next() && i < 4) {
row = parser.getRow();
rows[i] = row;
i++;

 

Any other function we have to use for scoped apps?

5 REPLIES 5

Hi Manisha,

So are you saying by increasing the property value of "glide.scriptable.excel.max_file_size" you are able to get the content of file more than 5MB

please share property value you update

I could see that property is used during import

Regards
Ankur

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader