Forums

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

Automate custom field sum in epic from other cutom field in Childs

Hakima Bilal
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 16, 2023

Hello,

I would like to know how I can sum the value of the custom field "# of major comments" from all the childs of an epic, and store the sum result in the custom field "# Total major comments" for Jira Data Center instance, using automation rule or Scriptrunner.

Thank you in advance

2 answers

0 votes
John Funk
Community Champion
June 18, 2023

Hi Hakima - Welcome to the Atlassian Community!

You should be able to create an Automation Rule to do this. 

Follow this guide in the Automation Rules playground and let us know if you run into any problems. 

https://www.atlassian.com/software/jira/automation-template-library/rules#/rule/9919294

0 votes
Trudy Claspill
Community Champion
June 16, 2023

Hello @Hakima Bilal 

Welcome to the Atlassian community.

The following post asks about summing up Story points, but I believe you can use the same logic with your custom fields.

https://community.atlassian.com/t5/Automation-questions/How-to-automate-the-sum-of-story-points-for-all-issues-under-the/qaq-p/1607809

Answer by @Gareth Cantrell 

Matthew Mallard March 11, 2025

I don't believe that's true. Custom fields cannot be summed using the normal .sum functionality

John Funk
Community Champion
March 11, 2025

If they are number fields, yes they can. 

Matthew Mallard March 11, 2025

I thought the same thing but ended up having to resort to a workaround using "Send web request" action. More details found here: https://community.atlassian.com/forums/Jira-articles/Automation-for-Jira-Send-web-request-using-Jira-REST-API/ba-p/1443828

 

This is Jira Datacenter, not cloud. For Cloud, .sum of custom number fields works fine, so I'm told.

John Funk
Community Champion
March 11, 2025

That post is very old. And this one is two years old. If you have a specific example you need help with, then create a question for folks to respond to. 

Like # people like this
Matthew Mallard March 11, 2025

Old or not, I stumbled upon it. Others are will to. Simply trying to share additional knowledge and prevent others from having to go through the struggle I went through to workaround .sum not working. Thanks John!

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
TAGS
AUG Leaders

Atlassian Community Events