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

Compiled formula is too big to execute (6,581 characters). Maximum size is 5,000 characters,



ISNULL(Major_Defect_UAT_Partner__c), ISNULL(Minor_defect_UAT_Partner__c), ISNULL(Compliance_HC__c), ISNULL(Compliance_Launch__c )








above formula I'm using when all the fields are null show null else calculate the value..the problem is I can't saved it showing an error..Compiled formula is too big to execute (6,581 characters). Maximum size is 5,000 characters


If you're referencing information / creating info that has a lot of characters for the system to read (over 5,000 characters), this can happen.  


These might help:


This also seems to have helped some people:



I am not good enough to help fix the formula, but that might be a start.


You also might need to use an Apex Trigger, instead.





Shannon HaleShannon Hale

It looks like you are referencing each of the other fields in your formula 3 times each. This pulls in the compile size of each of those fields 3 times.


I'm guessing at least one of those fields is a large formula that is pushing you over the compile size limit for this field. For each of those, go into the formula field and click Check Syntax to get the compile size. Start with the biggest one and see if you can reduce it by writing the formula more efficiently.


If you can't reduce the compile size sufficiently, and you are using Enterprise Edition or Unlimited Edition, you can use a workflow field update to set the value of one of your large formulas: This Help & Training article explains how to do it:


Unrelated - ISNULL() should not be used in new formulas, it's deprecated. Use ISBLANK() instead.

Tymon FrancisTymon Francis
On the same page as Shannon, I wasn't able to reduce the size of my formulas, so I created a Proxy text field, then updated that field with a Field Update. I then referenced the proxy field in my other formula field and saved thousands of characters. Hope this helps. 
Andrew RoweAndrew Rowe
Doesn't work on Pricebook Entry.
Nothing can be done on this object.  No Workflows, No Field Updates, No Triggers.
I'm working on developing some local currency fields as we cannot turn on multi-currency due to other functionality we utilize.
There are requests to open up triggers on this object which will fix these issues.
However, those have been open for years and my personal conversations with the Engineering team (over several hours) and our sales team...they are not indicating that this is any sort of priority or even on a radar screen for development.