[SalesForce] Workflow rule not working as expected(not on update of a criteria)

I wrote one WF rule which seems to be not working

My requirement is whenever "Person's age" becomes 65 or more then it should update one field called 'Insurance Marketability'to a value called'Education Only'.

"Person's age" is a formula field on contact object which derives its value from another date field called "Date of Birth"."Insurance Marketability" is a picklist field.I am using Person's account concept so I have built logic inside Process Builder and WF created on Account.

Since there are few limitations of formula fields usage with PB and WF because any updates on Formula fields is not considered as DB events hence my field "Insurance Marketability" was not set to "Education Only". So I wrote one WF rule with Rule Criteria as "TODAY() – Date_of_Birth__pc >= 65" and Evaluation Criteria as "Evaluate the rule when a record is created, and every time it's edited" and created one Field Update action on same as Update Insurance Marketability to Education Only.Also I checked "Re-evaluate Workflow Rules after Field Change" field to true

enter image description here
enter image description here

But it seems WF is only working. Its only working when I am clicking on EDIT button and then SAVE button on Account. Ideally my intention is suppose an account's date of birth mentioned as 7th May 1953 then on 7th May 2018 Insurance Marketability should be set as "Education Only" by only just refreshing that particular records or opening up that particular record(not with clicking on edit button and then simply click on save button).

When I changed my evaluation criteria to subsequently met criteria then WF rules is not triggering anything.

I have done researches on formula fields limitations in WF rule and PB so I went for creation a logic on Date of Birth field instead of Person' Age field but still I have no luck and stuck at same place only.

Also I read in some forums when I was doing researches that only thing which can save me here is a Scheduler but problem is I am novice in Customization and no idea about Scheduler

Any help will be greatly appreciated.

Many thanks in advance.

Kindly help

Best Answer

You are using a formula field. Formula field is not stored in database and are evaluated at run time.

  1. As workflow rule fire only when there is change in data create/edit. As change in formula field is not excatly change in data as its not a field in database, thus the workflow wont fire automatically when Applicant reaches a certain age.
  2. When you edit that record, then workflow rule fires and evalutes the criteria. During evaluation it finds that formula value has changed and should trigger a field update.
  3. subsequently met criteria only fires when old value is different than new value. So before DML the formula value and after dmL formula value is same, it wont trigger the field update.

You have to use Scheduler/Time Based workflow for this behavior.

Below link mentions both approches to send email via Scheduler and via time based workflow. http://www.simplysfdc.com/2015/02/salesforce-send-birthday-email.html

Related Topic