I'm hoping I can create an automation rule that:
when a new subtask (a subtask type specifically created for this)is created it is automatically linked to issues that are in a particular status AND have a particular field set, so for example:
Rule is along the lines of when subtask X is created, link to any issues in status "testing" that has the custom field of ready is set to "yes", so if there are 40 issues in status "testing" but only 4 have the ready field set to yes, then it would link the 4 issues.
Add to that if any of the issues in status "testing" are changed after the inital subtask is created, the ready field is set to yes then it would link to the subtask originally created
Might be a tall ask for automation but lets see if it can be done.
Hi @Dennis_H
What have you tried thus far to accomplish this? If you post an image of the rule you have thus far, and any errors, that will help the community to provided you suggestions.
For some information about example rules and documentation, please look here:
Best regards,
Bill
I really don't have a rule formed yet, that what I'm trying to figure out. Can automation be used successfully for this request? It's a bit tricky (to me anyways) and I'm looking for assistance with forming something that will work.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Gotcha; I wanted to check if you already have something which to consider.
Would you also please describe the problem you are trying to solve? I am wondering if these rules could create conditions of duplicate/unnecessary links when there is already a parent/child relationship between some issues.
The first rule you describe is possible:
For the part you describe as "And to that..." for later issue changes which seems a bit unclear to me. What would change in an issue that would lead you to link it to the already created sub-task?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
So if I have a subtask with 3 issues already linked to it because the field in the issue was set when the rule ran those would be linked, however if another issues field is set with a certain value I'd like it to link to the issue that matches (the field is set the same), so for example:
I have subtask "subtask 1" created and when it was created it checked all of the issues in status "ready" and linked any issues that had a custom field set to "yes" and ignores ones with the custom field set to "no". Now if after the subtask is created I'd like to create a rule that if an issue in status "ready" the custom field is changed to "yes" then it links to the subtask that was previously created
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for adding that information. Here is the challenge you need to address:
When the currently unlinked issue, in a status of "ready", changes its custom field value to "yes"... How does it know to which sub-task to link?
If you are able to answer that question (TBD below) you can create a rule to add the link later:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I could create a field specific to the the subtask as there will only be one at a time, so the subtask could have a custom field of "link" and we are able to set a value upon creation. Then if one of the issues in ready has the same field and it's set to the same value as the subtask it could be linked (I think?),
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That might work; I suggest building the first rule (on sub-task created) and testing it. Then create the second one to confirm it works as you expect when trying to select back to the sub-task.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Is there a way via JQL to compare fields in two different issues? If so I could set a rule that when the "link" value is set, it used JQL to find the matching issue then link to that issue?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Not out of the box, as JQL isn't a SQL. With automation you have additional options:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I tried the following and the JQL didn't work but the direct reference did
JQL
project = "MY project" and status = Open and "Service type[Dropdown]" = MYservice and issuetype = my-subtask
Gave the following error:
Error linking issuesproject = "My Project" and status = Open and "Service type[Dropdown]" = MYservice and issuetype = my-subtask: Issue does not exist or you do not have permission to see it.
But if I just set the issue # instead of the JQL it linked. If I run that query in the filters section it pulls up the correct issue. Not sure about the permissions issue as the creator of the issue is Automation for Jira.
If I can get this to work I think it will suit my needs.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am trying to understand the context for that error message. If this is from JQL in a rule, would you please post an image of the entire rule? Thanks!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for that information.
Is this rule running in the "DCS Development" project? If not, rules which impact multiple projects need to be defined an run at a global scope.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That is curious... Have you tried to branch on the JQL and then link them, one by one to the trigger issue?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Something like this, with only a small change to your rule:
This will link the trigger issue to each issue returned by the JQL in the branch.
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.