Question about the Calculated Date/time field

I have JIRA Miscellaneous Custom Fields add-on installed, and I'm try to setup a custom field of type Calculated Date/Time.

I want to know the number of days between when an issue is resolved, and when it has completed independent verification. I already have a custom field called "VerifyEnd" (FieldID=11200) that automatically posts the current date on transition out of the Verification state.

It seems like this forumula should work, but I'm not having any luck. Suggestions?

<!-- @@Formula: org.apache.commons.lang.time.DateUtils.addDays(issue.get("resolution_date"),("FieldId=11200")) -->

3 answers

1 accepted

First of all, I don't see what you mean by "("FieldId=11200")" in your formula.

Then, I believe you want a date difference, not to add two dates. There are several examples in other questions:

Thanks. "("FieldId=11200")" is the FieldID of a custom field in my instance. I believe that is the correct syntax to have the formula recognize it.

I've never seen this syntax, and I'm positive it cannot be used in your context. Custom field names are in the form: "customfield_11200". So issue.get("customfield_11200") will return the value of that field.

Yep, you are right, I mis-read some instructions. Thanks! I'll see if this clears up my problem.

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Bridget Sauer
Published Thursday in Marketplace Apps

Calling all developers––You're invited to Atlas Camp 2018

 Atlas Camp   is our developer event which will take place in Barcelona, Spain  from the 6th -7th of   September . This is a great opportunity to meet other developers and get n...

77 views 0 5
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you