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
Gregory512Gregory512 

Total GPA formula is too big - any other options?

I'm trying to create a GPA formula that looks like this:

 


(Phase_1_Grade_Points__c + Phase_2_Grade_Points__c +
Phase_3_Grade_Points__c + Phase_4_Grade_Points__c + Phase_5_Grade_Points__c +
Phase_6_Grade_Points__c + Practicum_Grade_Points__c ) / (Phase_1_Credits__c +
Phase_2_Credits__c + Phase_3_Credits__c + Phase_4_Credits__c +
Phase_5_Credits__c + Phase_6_Credits__c + Practicum_Credits__c)

 

 

I end up with an Error telling me the formula is too large.  Every value referenced in the above formula is similar to this:

 

CASE(Phase1_Grade__c , 'A', 12,'B',9,'C',6,'D',3,'F',0,0)

 

Is there any way to get around the error?

 

Thanks for your help.

Kent ManningKent Manning

Could you create two hidden formula fields on your object, one that would total the grade and the other that would total the credits, then do the division?

 

Hidden field 1:

 

Grade_Total__c(Phase_1_Grade_Points__c + Phase_2_Grade_Points__c +
Phase_3_Grade_Points__c + Phase_4_Grade_Points__c + Phase_5_Grade_Points__c +
Phase_6_Grade_Points__c + Practicum_Grade_Points__c )

 

 

 

Hidden field 2 :

 

Total_Credits__c(Phase_1_Credits__c +
Phase_2_Credits__c + Phase_3_Credits__c + Phase_4_Credits__c +
Phase_5_Credits__c + Phase_6_Credits__c + Practicum_Credits__c)

 

Field 3

 

Grade_GPA__c = (Grade_Total__c / Total Credits__c)

 

This might work, but I'm concerned that all of your formulas are adding to each other and causing your main formula to reach the maximum number of characters allowed. 

 

You might also check the help and training section and type in "formula govenor limits" or click here. There should be an article called Formula field exceeds manimum number of characters in the Solutions Found section. This helps you figure out how to split up complex formulas.

 

Hope this helps.