You need to sign in to do that
Don't have an account?
prakash reddy 65
nt allowing to save an formula field
As i was trying to save a field and it shows the following error:
Error: Invalid Data.
Review all error messages below to correct your data.
Formula(s) that reference this field are no longer valid: Compiled formula is too big to execute (5,138 characters). Maximum size is 5,000 characters (Related field: Formula)
The formula of the field is:
IF(OR(ISPICKVAL(Code__c,"SAP"),
ISPICKVAL(Code__c,"MBS"),
ISPICKVAL(Code__c,"SAD"),
ISPICKVAL(Code__c,"SADP"),
Account.cost__c ,
IF(OR(ISPICKVAL(Code__c,"SAC"),
ISPICKVAL(Code__c,"AEM"),
ISPICKVAL(Code__c,"CC"),
0,
IF( AND (OR( ISPICKVAL(Code__c ,"JR"),
ISPICKVAL(Code__c,"DR")),
NOT(ISPICKVAL(Account.Type__c,""))),
1400,
IF( OR(ISPICKVAL(Code__c,"AE")),
Account.cost__c/9,0))))
Can anyone please help me with this (or) else can anyone suggest me how to use CASE function for this type of formula
Thanks,
Error: Invalid Data.
Review all error messages below to correct your data.
Formula(s) that reference this field are no longer valid: Compiled formula is too big to execute (5,138 characters). Maximum size is 5,000 characters (Related field: Formula)
The formula of the field is:
IF(OR(ISPICKVAL(Code__c,"SAP"),
ISPICKVAL(Code__c,"MBS"),
ISPICKVAL(Code__c,"SAD"),
ISPICKVAL(Code__c,"SADP"),
Account.cost__c ,
IF(OR(ISPICKVAL(Code__c,"SAC"),
ISPICKVAL(Code__c,"AEM"),
ISPICKVAL(Code__c,"CC"),
0,
IF( AND (OR( ISPICKVAL(Code__c ,"JR"),
ISPICKVAL(Code__c,"DR")),
NOT(ISPICKVAL(Account.Type__c,""))),
1400,
IF( OR(ISPICKVAL(Code__c,"AE")),
Account.cost__c/9,0))))
Can anyone please help me with this (or) else can anyone suggest me how to use CASE function for this type of formula
Thanks,
This is a compile size error. It basically means that there are either complex formula or too many formula. Please refer to this link (https://resources.docs.salesforce.com/204/latest/en-us/sfdc/pdf/salesforce_formula_size_tipsheet.pdf)for additional information.Also for the formaul you posted try using CASE function.