Datablaze - Formula to calculate new date

I need a formula to calculate days from an entered date on Datablaze.

I have an expiration date and I want a different field that calculates 60 day before that date. I've tried a few things, but am failing. Help! :slight_smile:

I love when I ask stupid questions and then solve my own issue.

datetimeadd(`lease expiration date`, "60", D)

Worked.

Hey Stephanie,

It might just be the community's formatting of your snippet but I wanted to point out that what you posted would add 60 days to the date, not subtract. This would be how to format it for going back 60 days (in my case I just made the lease expiration date today):

{`lease expiration date`={time: YYYY-MM-DD}}
{=datetimeadd(`lease expiration date`, "-60", "D")}

1 Like

Yeah - fixed that after I posted. Thx!