Previous and New Value of the Numeric Field

Muhammad Moazzam Hassan
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 22, 2024

Hi,

I want to retrive the old and current value of my numeric value, which I need help in syntax which I can use in the automation rule to retrieve it my Field Name is Logged Hours.

1 answer

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 22, 2024

Hi @Muhammad Moazzam Hassan 

For a question like this, please post an image of your complete automation rule, images of any relevant actions / conditions / branches, an image of the audit log details showing the rule execution, and explain what is not working as expected.  Those will provide context for the community to offer ideas.  Thanks!

Until we see those...

If your trigger is for a change to that field, please use the changelog smart value for the current and prior values of the field: https://support.atlassian.com/cloud-automation/docs/jira-smart-values-issues/#--changelog--

If your trigger is not on a change to the field, what you ask is not easily possible with an automation rule, as it would need to get the changelogs using the REST API, and filter them for your field to find the changes...and that may not work if there are many changes listed in the log.

Kind regards,
Bill

Muhammad Moazzam Hassan
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 23, 2024

So sorry fo this,

Let me explain.

Whenever the Logged Hours field is updated the rule will trigger and update the parent. But I have another field name as Current Month which store the Logged Hours of only current month so whenever I am updating the Logged Hours field I need the previous value and the new value then  I will subtract it and add the value to the current month.

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 24, 2024

Again, please post images of your complete rule and audit log details showing the rule execution.  Those will provide context to offer better suggestions.  Thank you.

 

When you describe "whenever the Logged Hours field is updated", do you mean a custom field with that name or that you are using the built-in time tracking features of Jira.

Muhammad Moazzam Hassan
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 8, 2024

Sorry for not posting images, basically I want the changelog of the value "Logged Hours: is the customfield so whenever its value changes I want to retrieve its old value which I have achieved via Changelog.

Thanks

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
TAGS
AUG Leaders

Atlassian Community Events