Smart value to access issue.id of the linked issues duplicate

Serge Neuman May 15, 2023

In Jira automation, I have an issue that triggers an automation and that duplicates another issue. My automation creates a new issue. I want this new issue to duplicates not only the issue that has triggered its creation but also the issue duplicated by this issue that has triggered the creation.  

Typically I have PI-42 that duplicates Prog-42
When PI-42 transitioned from one state to another, then an automation is launched. It create Dev-42. I want to link Dev-42 to Pi-42 and states it duplicates it. I also want to link Dev-42 to Prog-42 and states it duplicates it. 

The first one is easy to do, I just have to link my issue to the most recently created issue and chose "is duplicated by". 
The second should be easy using the additional information for linked issues except that I do not find the smart value that gives me the id of the {{linkedIssues({{issue.key}}, "is duplicated by")}}.

Has someone the answer? 
Thanks

1 answer

1 accepted

1 vote
Answer accepted
Fernando Eugênio da Silva
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 15, 2023

@Serge Neuman 

 

You can do this by using the lookup on the link type and then fetching the reference value.

As issues are linked between different projects, you will need to make this rule global, just so jira will fetch the other associated issue values.

Here's how to do this using the lookup:

Define the Trigger of your automation:

Condition > As the rule needs to be 'global', put a condition for the rule to proceed only if the issue trigger is from a certain project

Action: LookupIssues > Insert a JQL: issue in linkedIssues({{issue.key}},"is duplicated by")

Then, to get the ID of the issues, use the smartvalue: {{lookupIssues.id}}

Sample rule:

Screenshot_109.png

See the doc reference: Advanced search reference - JQL functions

Hope this helps :)

Serge Neuman May 18, 2023

Thanks.
I think it works, but as i was using a free subscription to work on my POC, I have reached the limits of automation rules I can run and need now to migrate everything to the subscription of the firm where I will be able to finalize the tests.  

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events