function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
sivasankar.ksivasankar.k 

Is there any way to increase heap size for an organization? due to Apex Heap Size is too large error and followed best practices as well.

Hi All,

Is there any option to increase heap size for an organization. As we are receiving Apex Heap Size is too large error, we have followed the best practices to handle the heap size even though we are not able to handle it. As our report generating 800 pages PDF with data.

Please guide me with any solution for this as it is urgent..
Frédéric TrébuchetFrédéric Trébuchet
Hi,

If there is a way to increase the heap size, only Salesforce's guys can do it (I hope so!).
So, I think you have to contact your customer support. No choice.

But, have you tried to limit the size of your PDF - for example to 200 pages? what happened?
If you can split your job's result, it could be a way, generate 4 PDF files (or 2, or 8, or...) then merge them together.

Hope this helps,
Fred