Skip to main content

Hello, I’m trying to use the new DATE_ADD function that is listed in the 12.2.8 Spark Notes. I just upgraded our sf production environment to this update.


I don’t see the function listed in the formula functions, so I’m not sure it’s even there. But, I also tried to use it manually and nothing is happening. I’m using API v1. Here’s excerpt from Release Notes and then my code.


 CORE-2365

New formula functions: DATE_ADD and DATE_DIFF

Working with dates can be a complicated process, so we’ve added two new functions to simplify things:

DATE_ADD is used to take a source date, add a specified amount of time to it, and return a new date. For example, you could add fifteen minutes, two weeks, five months, and so on.

DATE_ADD( {{MyDate}}, 1, WEEK )

You can even subtract time from a date by using a negative integer with the formula.

DATE_DIFF is used to calculate the difference between two dates. You can find out how many minutes, weeks, months, and so on between two dates—whether a specific date or the current date—with this function.


DATE_DIFF( {{MyDate}}, {{MySecondDate}}, DAY )


My Code


DATE_ADD({{AcctSeed__Date__c}}, 30, DAY)

Hi Sam, I just double-checked on this. This is currently only available with our V2 components.


Gotcha. Thanks for the quick reply!


So unfortunate. Exactly what I needed. Why not have this in V1? At the very least update the docs to exclude these features from V1.


Thanks for your feedback here, Pat. We’ve logged your feedback on the the documentation.


Hey Team. Any chance those of us on v1 can just get the code for DATE_ADD so we can add it to our custom formulas? I’d rather not recreate it if someone’s already done the work.


Thanks!