Skip to main content
Pablo Garfunkel (RevOps Engine) a posé une question dans #Formulas
Hi, hoping someone can tell me what am I doing wrong here.

Trying to prooduce a custom formula that:

  • will return "Comm" if opportunity type is New Logo or Cross Sell
  • will return "n/a" if sum:maint = sum:amount
  • will return "n/a" if opportunity type is Renewal
  • will return "Comm" if opportunity type is Upsell AND CSE Booking field is 'Yes'
  • ELSE it should return "n/a"

Here's the formula I plotted; it keeps gicing me Error when encoding row-level formula: Syntax error. Extra ','

IF (ispickval(TYPE),"New Logo"), "Comm",

IF (ispickval(TYPE),"Cross-Sell"), "Comm",

IF (ispickval(TYPE),"Renewal"), "n/a",

IF (Opportunity.Sum_Maintenances__c.CONVERT=AMOUNT.CONVERT),"n/a",

IF (AND(ispickval(TYPE),"Upsell"),(ispickval(Opportunity.CSE_Booking__c),"Yes"),"Comm","n/a")))))

Thanks in advance!
2 réponses
  1. 22 oct. 2022, 03:21
    Hi Pablo,

    The issue with your formula is that syntax of ispickval is incorrect , The ispickval closing bracket must end after the comparision value like :

    ISPICKVAL(picklist_field, text_literal)

    Documentation : 

    https://help.salesforce.com/s/articleView?id=sf.customize_functions_ispickval.htm&type=5

     

    IF(ispickval(TYPE, "New Logo"), "Comm",

    IF(ispickval(TYPE, "Cross-Sell"), "Comm",

    IF(ispickval(TYPE, "Renewal"), "n/a",

    IF (Opportunity.Sum_Maintenances__c.CONVERT=AMOUNT.CONVERT,

    "n/a",

    IF (AND(ispickval(TYPE,"Upsell"),ispickval(Opportunity.CSE_Booking__c,"Yes")),

    "Comm",

    "n/a")))))

    and also if you are comparing 2 values we should not end the bracket of IF condition before the values.

    Hope this helps, If so kindly mark it as best answer

    Thanks,

    Karthik

     
0/9000