Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

I'm trying to create an automation to calculate a date based on a date and number field

Sarah Catania June 24, 2025

I have three custom fields:

  • Cybersec Last completed: {{issue.customfield_13488}}
  • Cybersec validity length (years): {issue.customfield_13489}}
  • Cybersec next due: {{issue.customfield_13490}}

 

I want to populate a date in the Cybersec next due that is the difference (in years) of the Cybersec Last completed date according to the number in the Cybersec validity length (years)

This automation results in a success, but for the same year!

{{issue.customfield_13488}}.diff({{issue.customfield_13489}}).Years}}Cybersec rule.jpg

 

Cybersec fields.jpg

How can I get it to increment by the number of years in the Cybersec validity length (years) field

1 answer

2 votes
Akash Singh
Community Champion
June 24, 2025

Hi @Sarah Catania 

You were almost there, you could simply use Date plus function to get the Due date. A valid smart value for the operation would look something like,

{{issue.customfield_13488.plusYears(issue.customfield_13489)}}

You can read more about other smart value date function here

In case Cybersecurity increment field is of text field type then you would need to convert to a number before using which changes the smart value to,

{{issue.customfield_13488.plusYears(issue.customfield_13489.asNumber)}}

 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events