The below is a part of a formula that i wrote, everything is working fine, except for the below.

My need is, if the " Renewal Month" field ( which is a month picklist field with values as January, february etc). If the month choosen is, less than the current month , it will satisfy certain crtiteria which is working perfect. But if the choosen month is greater than the current month ( i.e i choose : December" but the current month is " November"), where I am getting issue. Then the task date created would be 1/11/2016 i.e current year and minus one month from choosen month ( i.e December).

I wrote it as:


But as month is today i have taken, so its giving value as 1/10/2016 , so rather than december taking as november ) today month. So, i changed it as per below , but its showing me syntax error. can anyone plz rectify my below formula. thnx  


CASE( [Lead].Renewal_Month__c, "January",1, "February",2, "March",3, 
 "April",4, "May",5, "June", 6, "July", 7, "August", 8, "September",9, 
  "October", 10, "November", 11, "December", 12,NULL) - 1
  • The question title should be used to give a summary of the question, please don't include things like "need a fix asap". – Matt Lacey Nov 17 '16 at 3:43

Seems like error with: [Lead].Renewal_Month__c

-If the date formula field is in the Lead object, then just write: "Renewal_Month__c"

-If it's in child object of Lead, then write: "Lead.Renewal_Month__c" (Assume Lead is the field API name in the child object)

| improve this answer | |
  • Hi Liron, the field is in Lead object itself. Let me try your suggestion. Thanks – sourav Nov 11 '16 at 4:29
  • Actually below is my whole formula, – sourav Nov 11 '16 at 4:35
  • ohh i cant post it, due to char limittion. But it doesnt worked. As i am using processs builder, i am choosing the field an its giving the name as [Lead].Renewal_Month__c because i have taken the Record type in process builder as " Task", so i.e if my formula work it will create a task with the due date as per my formula. thnx – sourav Nov 11 '16 at 4:39
  • If you can follow my this related question link and suggest plz, thanks, salesforce.stackexchange.com/questions/148233/… – sourav Nov 11 '16 at 4:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.