I have a total amount formula field ((all products * term) + one time amount) on an opportunity. Also I have 3 different record types for opportunities. Now the sales team want this field to show for 2/3 record type the above and only for one specific record type the formula - 40 %.

I tried it with one and got a syntax error (Missing ")":

If((RecordType.DeveloperName = "ATS", ((Monthly_amount__c * Term__c) +  Onetime_amount__c) * 0.6),
(Monthly_amount__c * Term__c) +  Onetime_amount__c)

Also not sure how to put the OR for the second record type in it. BR Alex

  • Your brackets are wrong.
    – Phil W
    Mar 22, 2023 at 13:27

1 Answer 1


The IF formula function takes three parameters:

  1. The expression
  2. The value when expression is true
  3. The value when expression is false.

Try updating this like:

((Monthly_amount__c * Term__c) + Onetime_amount__c) * IF(RecordType.DeveloperName = 'ATS', 0.6, 1.0)

The common part of the calculation doesn't need to be duplicated, so I took it out of the IF.

  • Awesome. Thank you. Works like a charm @phil-w
    – Alex M.
    Mar 22, 2023 at 14:11

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .