Date Diff function enhancement in Rules Engine

  • 7
  • Idea
  • Updated 2 weeks ago
  • Under Consideration
Currently in Date Diff function we can substract between two date values fields, can we also add
rule date in list of available values.

Eg Renewal Date - Rule Date 
Photo of Anirudh Allika

Anirudh Allika, Employee

  • 1,216 Points 1k badge 2x thumb

Posted 2 months ago

  • 7
Photo of Pele

Pele

  • 2,422 Points 2k badge 2x thumb
I too think this would be helpful. One thing we have setup in our instance to use in cases like the example here is a formula/date field on the Customer Info object in Salesforce with the formula TODAY(). This then becomes a field you can use in rules to capture the DateDiff between Renewal Date and Rule Date. 

Having a "Rule Date" field available in DateDiff calculations would become helpful for me in rules where I have to Merge the Customer Info object just for the "Today" field we have created. I often create a dataset from the Customer Info object just for this handy "Today" field when setting scorecard rules from data that is in MDA. e.g. usage data is in MDA, I can't create a similar formula/date field in the MDA object (at least, I don't think this is possible), so to calculate something like "number of days since last user login" I have to join the field "Today" that I have setup on the Customer Info object. 
Photo of Sai Ram Pulluri

Sai Ram Pulluri, Official Rep

  • 12,426 Points 10k badge 2x thumb
Hi Anirudh/Pele, 

This is a great use-case,this is already added to our road-map and will let you know once we take it up for release!

Thanks for posting!
Photo of Pele

Pele

  • 2,422 Points 2k badge 2x thumb
Awesome news– thanks, Sai!
Photo of Prabhat

Prabhat

  • 372 Points 250 badge 2x thumb
Hi All,

This feature is coming in October release. you should be able to achieve following
  • Rule Date will be a new formula - help you get Rule Date as a show field.
  • Date Diff will support difference from any Date field to Rule Date
  • Date Diff can be now signed value 

(Edited)