Skip to main content
Wayne Gladman (Ebsta) 님이 #Formulas에 질문했습니다
Hello, I'm trying to build a lead scoring formula based on age of a lead

I've created the below formula but am getting the error:  Incorrect parameter type for function 'IF()'. Expected Text, received Number. (I've tried this as a CASE formula and got a syntax error highlighting <=)

IF(Lead_Age__c,<=5 and >=0,"10",

IF(Lead_Age__c,<=10 and >=6,"6",

IF(Lead_Age__c,<=35 and >=11,"9",

IF(Lead_Age__c,<=60 and >=36,"4",

IF(Lead_Age__c,<=90 and >=61,"2",

IF(Lead_Age__c,>=91,"8",

null))))))

Basically the formula is meant to say for the first line for instance if the lead age is between (or equal) 0-5 then the score will be 10.

Not sure why an IF formula can't produce a number so any help would be appreciated.

Thanks,
답변 3개
  1. 2021년 9월 8일 오전 3:25

    Hi  Wayne Gladman,

    Try this formula,

    IF((Lead_Age__c <= 5 && Lead_Age__c>=0), 10,  IF( (Lead_Age__c <= 10  && Lead_Age__c >=6) , 6,  IF((Lead_Age__c <= 35 && Lead_Age__c>= 11), 9,  IF((Lead_Age__c <=60 && Lead_Age__c >= 36), 4,  IF((Lead_Age__c <= 90 && Lead_Age__c >= 61), 2,  IF(Lead_Age__c >=91, 8, null) ) ) ) ) )

    If this helps,please mark it as best answer

     

    Thanks.
0/9000