Skip to main content

Hi! I am trying to create a formula where if the Record Type = Wholesale OR the field "Commercial Heating Oil" = TRUE, then execute one specific formula, and if it does not match either of those criteria, then calculate a different formula.

 

Currently I have this, but I am receiving an error of "Error: Incorrect number of parameters for function 'CASE()'. Expected 2, received 2," which is very confusing to me. 

 

OR(Commercial_Heating_Oil__c, TRUE, CASE(RecordType.Name,

"Wholesale"), ((( Annual_Volume__c * Unit_Price__c) * 0.10)/30)* ABC__c,

((( Annual_Volume__c * Unit_Price__c) * 0.15)/30)* ABC__c)

답변 3개
  1. 2021년 8월 3일 오후 8:22

    Hi Samantha,

     

    Try this

     

    IF(AND(

    Commercial_Heating_Oil__c,  

    RecordType.Name= "Wholesale"),

    ((( Annual_Volume__c * Unit_Price__c) * 0.10)/30)* ABC__c, ((( Annual_Volume__c * Unit_Price__c) * 0.15)/30)* ABC__c

    )

0/9000