Hi,
I am trying to update a custom field on the parent issue based on the number of subtasks using the JIRA automation. So far, I was able to count the number of subtasks under the issue using {{issue.subtasks.size}} which is working perfectly!
I would now want to count the subtasks that are "Closed" and update the count in the parent issue. What combination of the smart field works for this?
This is how I done by merging both solution. I am doing batch automation on 1000s of issues and its sub-tasks.
I got total subtask using {{issue.subtasks.size}}
and number of done after lookup {{lookupIssues.size|0}}
Hi @Shamanth
First thing, I am using Jira Cloud and not Server/Data Center.
As Jack notes, your version does not have Lookup Issues, so perhaps try the bulk-handling features with a JQL branch, and then use the {{issues}} smart value. Note that one is plural to handle the issues as a set.
Please look here to learn about that feature: https://confluence.atlassian.com/automation/run-a-rule-against-issues-in-bulk-993924653.html
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Shamanth , welcome to the community.
See if you can work the following into your rule. Please note that the last action is simply a means of logging the value for test purposes. I'm unsure exactly what your action plans are such as email.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Jack,
Thanks for responding!
Let me explain about the 1st automation rule that I have successfully created. In this rule, I will be counting the total number of subtasks under the parent issue and update that number to a custom field named 'Total Findings' of the parent issue.
Now I would like to replace the smart value {{issue.subtasks.size}} with another smart value that can count the number of subtasks with status=Closed. How can I achieve that?
Also, I tried replicating your rule, but unfortunately I could not find the Lookup Issues function.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can take what I gave you before and simply make your action be to edit the field of the parent with the smartvalue that I showed in the log action.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am sure that your solution would work, but I am currently on JIRA v8.20 and this lookup function is still not available to me. I am waiting for my organization to deploy the upgrade after testing.
Any alternative solution you might be aware of?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Basically this but replace "Description" with your custom field.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Ah....I missed that you are on server. It may be different but a bit surprised that what I show is not supported there. Can you try build the automation I suggested? Maybe, just as a test replicate exactly?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
And no, I do not know of any alternative here.
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.