Forums

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

Summing up fields from multiple Jira tasks

Tevik Raudanskis February 4, 2022

Hi Everyone,

I'm quite new to Jira and I'm not a developer...unfortunately. But I like automation:) I read through lots of threads here but did not find an answer to my problem. And it looks like this is not supported. But I'll ask anyways:)

We receive  Jira tasks for new Customer accounts creation and more. One of the fields in our Jira tasks is called "Subscriber Number". It's reflected as a number, but I believe it's a text field. At the end of each month I have to extract this field from all monthly tasks created and to sum it up.  For now I set up CRON schedule to run in on the first day of each month. And it works ok sending me a monthly email listing describing each task's Subscriber Number. Here is what I have set up for now using Project Automation:

When rule executes...

run a JQL search and pass results to subsequent conditions and actions ==> getting my search results. No issues here.
Then I'm sending email with very simple content generated by
{{#issues}}
<li>{{Subscriber Number}}</li>
{{/}}
The result is like this:
  •   21
  •   400
  •   293
  •   525
After the email is received I simply copy it to excel, editing and summing it up.  Lately we are getting about a hundred tasks each month so the manual work became somewhat tedious:)  I know there is an option to generate xls from Jira but I'm pretty sure we don't have this option installed.
I would greatly appreciate any suggestion if sum up automation is possible for a task like this!
Thank you!

1 answer

1 accepted

0 votes
Answer accepted
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.
February 4, 2022

Hi @Tevik Raudanskis -- Welcome to the Atlassian Community!

First thing, you describe that field as "Subscriber Number".  That seems like an identifier for a subscriber to me and not something you would want to sum up, but count it instead.  Am I misunderstanding the meaning of that field?

Next thing, are you using Jira Cloud or Server/Data Center?

I ask because you note the {{issues}} smart value, and that is only supported currently for the Server/Data Center version.  The equivalent one for Cloud is to use the LookupIssues action to bulk-process issues.

With that covered, how many issues are you expecting per month?  If it is 100 or fewer issues, and you are using Jira Cloud, you could use an automation rule to sum these values with the following:

  • trigger: scheduled monthly, with no JQL
  • action: lookup issues, using the JQL you originally used in the trigger
  • action: send email with the total, as {{lookupIssues.Subscriber number.sum}}  Please check to confirm the smart value matches your field name.  To do that, use the information in this how-to article.

If you are using Server/Data Center, you would do this with the bulk-handling feature of {{issues}}:

  • trigger: scheduled monthly, with your JQL, and the option for bulk-handling enabled
  • action: send email with the total, as {{issues.Subscriber number.sum}}  Please check to confirm the smart value matches your field name.  To do that, use the information in this how-to article.

If it is more than 100 issues, consider instead either creating a saved filter and subscribing to it to send an email, or investigate the marketplace for reporting options that may let you do this in a dashboard.

Kind regards,
Bill

Tevik Raudanskis February 6, 2022

Thanks so much Bill for your reply!

I will try to find out if we use Jira on Cloud or is it on prem. 

The Subscriber Number was the only more or less "reasonable" field available to choose from as, unfortunately,  Jira admins don't add any additional ones anymore. Once I know the answer on Monday I will try to follow your guidelines. I will let you know as soon as I get some result.

 thanks,

Tevik

Tevik Raudanskis February 7, 2022

Good Morning Bill!

I'm rushing to let you know that the issue has been resolved!!! YAY! I decided to play around with your suggested instructions since it's only two of them. It appeared that we are running on prem instance and both of the following commands {{issues.Subscriber Number.sum}} or {{issues.customfield_13726.sum}} are returning the desired result. 

Thanks again for your prompt and professional response!

Tevik

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events