+ Start a Discussion
Kondal PatchalaKondal Patchala 

Case function in formula field limit exceeds

Hi ,
I have new request from my enduser to update the formula field. State_Code__c is the custome text field that stores the state code and country_code__c  is the formula field that stores country code based on Sate_code__c. used the case function in the formula to get the corect country code. Now we have added 4 new countrys so i need to extand tha case function with  50 extra states but unfortunatly the limit is exceeds and i am unable to do with case function . Can anyone please help me to sortout this issue .( ie. one country have many states but i am unabel to add or function in case.)

kInd Regards,
Hi Kondal Patchala,

If your formula field limit exceeds, then you cannot able to include more conditions into that..Only option is to go with apex code or trigger..

Thank You
Vatsal KothariVatsal Kothari
Can you share your formula field's code here?
Gaurav NirwalGaurav Nirwal
Please understand the limits field if it exceeds the limit field it can be given an error 
Using apex along with custom settings is definitely one option to achieve this but you should go for custom code only when you cannot achieve this using native framework of salesforce.com. And towards this I would suggest you to consider the following
• Reduce formula character (remember Character count includes spaces, carriage returns, and comments) if possible
• Introduce secondary formula field
• Leverage workflow field update

Can you post your Formula Code?