What is the size of data that can be written by GlideSysAttachment?

Takaaki Sawai
ServiceNow Employee
ServiceNow Employee

In the docs, the data size of content that can be retrieved with getContent() and getContentBase64() are limited to 5MB.

There is no mention of a limit regarding the data size that can be written with writeContent() and writeContentBase64().
Is the data size of writable content limited to 5MB?

 

I read this docs.

https://docs.servicenow.com/ja-JP/bundle/tokyo-application-development/page/app-store/dev_portal/API...

 

1 ACCEPTED SOLUTION

Community Alums
Not applicable

Hi @Takaaki Sawai ,

I don't think we have a data size mentioned anywhere for Writing .

files are written using GlideSysAttachment api with content type, name

	var attachment = new GlideSysAttachment();
	var DecodedBytes = GlideStringUtil.base64DecodeAsBytes(rawfile);
	var fileSysId = attachment.write(record, fileName, contentType, DecodedBytes);

View solution in original post

3 REPLIES 3

Community Alums
Not applicable

Hi @Takaaki Sawai ,

I don't think we have a data size mentioned anywhere for Writing .

files are written using GlideSysAttachment api with content type, name

	var attachment = new GlideSysAttachment();
	var DecodedBytes = GlideStringUtil.base64DecodeAsBytes(rawfile);
	var fileSysId = attachment.write(record, fileName, contentType, DecodedBytes);

Thank you for your answer.

Do you know if DecodeBytes that is 4th parameter in write() can write more than 5MB without any problem?

Community Alums
Not applicable

Hi @Takaaki Sawai ,

I guess it can!!