About the size of attached files

namiki
Tera Contributor


I would appreciate it if you could tell me about the attachment size for development instances.
I'm trying to verify how to manage queries in a case table for a development instance.
I would like to ask the following questions about the file size of attachments to each case record.

Q1
Is there an upper limit to the number of attached files per case record?
If there is an upper limit, please provide the "Maximum number and capacity of files per case record" and "Maximum number and capacity of files per case record".


Q2
Is there an attachment capacity limit for the entire instance?
If so, please let us know the "maximum number and capacity".


Also, we are planning to use CSMSuperSKU for production use.
I would appreciate it if you could tell me the upper limit in the case of CSMSuperSKU.

1 ACCEPTED SOLUTION

Community Alums
Not applicable

HI @namiki ,

There is no limit as such but there is restriction on maximum size of attachment

system property in mega bytes -> com.glide.attachment.max_size

 

But if you want to set a limit then you can limit the amount of attachments you can add to a record via email using property:

glide.email.inbound.max_attachment_count

 

To limit the amount of records attached to a record in the back end you need script. Create a Before Insert Business rule on the sys_attachment-table with following script:

var numberAllowed = 5;
var grAttachment = new GlideAggregate('sys_attachment');
grAttachment.addQuery('table_name', current.table_name);
grAttachment.addQuery('table_sys_id', current.table_sys_id);
grAttachment.addAggregate('COUNT');
grAttachment.query();
if (grAttachment.next() && grAttachment.getAggregate('COUNT') > numberAllowed) {
    current.setAbortAction(true);
}

 

Mark my answer correct & Helpful, if Applicable.

Thanks,

Sandeep

View solution in original post

1 REPLY 1

Community Alums
Not applicable

HI @namiki ,

There is no limit as such but there is restriction on maximum size of attachment

system property in mega bytes -> com.glide.attachment.max_size

 

But if you want to set a limit then you can limit the amount of attachments you can add to a record via email using property:

glide.email.inbound.max_attachment_count

 

To limit the amount of records attached to a record in the back end you need script. Create a Before Insert Business rule on the sys_attachment-table with following script:

var numberAllowed = 5;
var grAttachment = new GlideAggregate('sys_attachment');
grAttachment.addQuery('table_name', current.table_name);
grAttachment.addQuery('table_sys_id', current.table_sys_id);
grAttachment.addAggregate('COUNT');
grAttachment.query();
if (grAttachment.next() && grAttachment.getAggregate('COUNT') > numberAllowed) {
    current.setAbortAction(true);
}

 

Mark my answer correct & Helpful, if Applicable.

Thanks,

Sandeep