You need to sign in to do that
Don't have an account?
Nate Baker
Prevent division by 0
I have a formula field that averages survey responses and excludes null values. How can I prevent from dividing by 0 if all the responses are null? (If the second part of this formula = 0)
(IF(ISBLANK(CS1_Q1_answer__c),0,CS1_Q1_answer__c)+
IF(ISBLANK(CS1_Q2_answer__c),0,CS1_Q2_answer__c)+
IF(ISBLANK(CS1_Q3_answer__c),0,CS1_Q3_answer__c)+
IF(ISBLANK(CS1_Q4_answer__c),0,CS1_Q4_answer__c))
/
(IF(ISBLANK(CS1_Q1_answer__c),0,1)+
IF(ISBLANK(CS1_Q2_answer__c),0,1)+
IF(ISBLANK(CS1_Q3_answer__c),0,1)+
IF(ISBLANK(CS1_Q4_answer__c),0,1))
(IF(ISBLANK(CS1_Q1_answer__c),0,CS1_Q1_answer__c)+
IF(ISBLANK(CS1_Q2_answer__c),0,CS1_Q2_answer__c)+
IF(ISBLANK(CS1_Q3_answer__c),0,CS1_Q3_answer__c)+
IF(ISBLANK(CS1_Q4_answer__c),0,CS1_Q4_answer__c))
/
(IF(ISBLANK(CS1_Q1_answer__c),0,1)+
IF(ISBLANK(CS1_Q2_answer__c),0,1)+
IF(ISBLANK(CS1_Q3_answer__c),0,1)+
IF(ISBLANK(CS1_Q4_answer__c),0,1))
All Answers