Hello,
Looking for some help here.
I have researched many community solutions (by @Ravi Sagar _Sparxsys_ , @John Funk, and @Nir Haimov but still stuck at the last hurdle.
I have the following custom field's below for which automation is working fine. These are timestamp fields.
I want to populate another custom field (number) Time to First Reponse (TTFR), which is the difference between the "Acknowledged timestamp" and "Ready status timestamp", ideally in businessDays. Hours will work too if need be.
I have tested my automation conditions trying to hard code the TTFR edit issue to a number (2). and it populates fine. But when I insert the below formulae, the automation log shows success, but there is nothing outputted in the TTFR field.
-Formulae i have tried under "edit issue"
{{issue.Customfield_14474.diff(issue.customfield_14475).hours}}
or
{{issue.customfield_14475.diff(issue.customfield_14474]).businessDays}}
SCREENSHOTS -
Hi Anand,
I recreated your use case and this solution worked for me:
{{issue.Uhrzeit 1.diff(issue.Uhrzeit 2).businessDays}} -> returned the difference in days
{{issue.Uhrzeit 1.diff(issue.Uhrzeit 2)}} -> returned the difference in hours
What type is the field you are editing? I used a textfield which works fine.
"Uhrzeit 1" and "Uhrzeit 2" are my test fields.
Thanks lisa. I've tried number and now text as well. no results. I've also tried changing custom field reference from IDs to names.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Lisa Grau - "Uhrzeit 1" and "Uhrzeit 2" are these date time picker fields?
For me -
customfield_14475 and issue.customfield_14474 are date time picker fields and I am trying to calculate the difference to store the result in a custom field (Text Field (single line)) field. Ive also tried a number field.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Here's my audit log for the automation (success) for the result custom field... Result - Time to First Response (my result custom field - text) is "None".
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm sorry I couldn't manage to answer yesterday!
Both fields are Date Time Picker.
This is what my automation looks like:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you Lisa. Magically, this worked this morning for new issues. I appreciate your responses.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Update - my automation still had issues. The first time the value for "Update for Customer" field changed, the automation for the calculation ran successfully but no results as earlier.
Interestingly, the second time the "Update for customer" field is changed, the results were successfully outputted in the screen.
My analysis (by using @Lisa Grau manual trigger idea, suggested me value change triggers were causing it.
I just solved the issue by creating a manual trigger like Lisa suggested to run every night at 12 am.
Thank you again. Hope this helps someone else with the same problem.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi there,
I am also trying something similar and I was advised to look here but still can't figure it out.
Problem statement - We have two customfields defined: Time for Approval [in seconds] and Time for Resolution [in seconds], we are trying to do something like below but unable to get the customfield value.
Time to approve [customfield_XXXX] = {{issue.created.diff(now).seconds}} -- this works fine
Time to resolution = {{issue.created.diff(customfield_XXXX).seconds}} ---not working
Please suggest.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Did you catch the news at Team ‘25? With Loom, Confluence, Atlassian Intelligence, & even Jira 👀, you won’t have to worry about taking meeting notes again… unless you want to. Join us to explore the beta & discover a new way to boost meeting productivity.
Register today!Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.