I have seen several posts about this issue but I still haven't been able to get it to work.
We're on JIRA Cloud
Company Managed Project
I tried 2 different solutions, neither of which worked.
Here is the first (didn't have room to capture the entire screen but the first steps is the one at the right "Field Value Changed")
Here is the second one I tried
In the story points field I used
{{lookupissues.Story Points.sum}}
Any help would be greatly appreciated.
Hello @christopher_branaman
@Jehan Bhathena provided information about a version of a rule that could work for you. I want to address why what you have did not work.
To really explain why they didn't work though, I need to know in what way exactly do each of these not work? Without that information I can point out some possible problems.
In the first one you have two Lookup Issues actions; one based on something you called "Epic Key" and one based on "Epic Link". What is the one based on "Epic Key" supposed to be doing? Do you have a custom field named "Epic Key"?
Also be advised that the second Lookup Issues action overwrites the results of the first one. If you actually need to retrieve two sets of issues and combine the results; with one issue set based on Epic Link and the other based on Epic Key, those selections need to be combined in one JQL in one Lookup Issues action.
In the second rule the Lookup within the branch is wrong. You can't use the Epic Name from the Epic as the value when searching on the Epic Link field for child issues. You would need to use
"Epic Link" = {{issue.key}}
Additionally, Atlassian is deprecated the "Epic Link" field and replacing it with the "Parent" field. In many systems they have already disabled the ability to use the "Epic Link" field in screens and filters, or provide warning messages when the "Epic Link" field is used. This may not yet be true in your instance, but you may want to check on that.
Thanks for the response. In both cases (where user error is highly likely) "doesn't work" means that even though the Epics have many child Stories with Story Point values, the Story Points field in the parent Epic cards remain blank.
I will also give your Epic Link suggestion a try.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I would also recommend that you add a Condition after the Lookup to confirm that the Lookup returned results, and only edit the field in the epin if it did. You can used and advanced compare to compare {{lookupIssues.size}} >0 to confirm that the results set contains one or more issues.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Adding to Trudy's suggestions...
I see several errors in the rule image you posted, with invalid smart values: case and typos.
Smart values are name, spacing, and case-sensitive. When an invalid one is used, the rule uses null, and that often fails silently (with no error in the log). The smart value for Lookup Issues is this:
{{lookupIssues}}
And so for a company-managed projects, the sum of the Story Points from the lookup would be this:
{{lookupIssues.Story points.sum|0}}
Please try that in your edit, or write it to the audit log, to observe any differences.
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.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please remove the extra spaces or the smart value expression will not work:
{{lookupIssues.Story points.sum|0}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
OK so using that formula, it did result in populating the field with a zero. I tried a couple of other different numbers just to be sure. What would be the next step to get all the story points to tally?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Let's confirm you are getting any issues back...After the Lookup Issues action, please write this to the audit log with the log action:
lookup issues count: {{lookupIssues.size|0}}
If that logs the count as 0, no issues where found and the JQL needs to be adjusted.
With the on-going changes to sunset the Epic Link field, you may want to try changing your JQL for the lookup issues action, based on your rule structure. Let's assume your rule looks like this:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It looks like I've got it working now, thanks! One additional question. Based on the above rules, is it possible to search for Stories AND Bugs?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am glad to learn that is working for you! Please consider marking this question that Trudy and I helped you with as "answered". That will help others in the community with similar needs find solutions faster. Thanks!
And...yes, that query could find whichever issue types you search for. Assuming they all have the same parent, that would be this:
parent = {{issue.key}} AND issueType IN (Story, Bug)
To learn more about creating such queries, I recommend this free training from Atlassian:
https://university.atlassian.com/student/path/849533-gain-project-insights-through-jql
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sorry, last question. Which stage would
parent = {{issue.key}} AND issueType IN (Story, Bug) be placed?
Would that replace the current query I have for the Then: Lookup issues?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Nevermind, it looks like the following change to Then: Lookup issues did the trick.
issuetype in (story,bug) and "Epic Link" = "{{issue.key}}"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
There is a Automation Template for this https://www.atlassian.com/software/jira/automation-template-library#/rule/9919294, please can you check if this one helps?
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.
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.