Forums

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

Showing links from linked ticket

Matthew Young September 30, 2020

Hey everyone, so I honestly don't think this is possible but I know there are some brilliant people one here so who knows, it may be possible.

I currently have a jira query that looks for tickets (linked to a specific project) that have a resolution of unresolved. This is working as intended, but I've noticed that if someone then creates ANOTHER linked ticket off the linked ticket, I can no longer see it. For example, I have a project "PI" and in my list I see it has an unresolved linked ticket "ONT". If someone comes and links a ticket to "ONT" it does not show on my list.

I know this sounds crazy, and again I don't think it's possible, but I wanted to ask here just in case.

My original JQL:
project = "Production Issues" AND status in (Open, Reopened) AND issueFunction in linkedIssuesOf("resolution != Unresolved") AND issueFunction not in linkedIssuesOf("resolution = Unresolved") AND status != Reopened

1 answer

0 votes
Tessa Tuteleers
Community Champion
October 7, 2020

Hi @Matthew Young , 

You have Scriptrunner on your instance, awesome! Great news, this is in fact possible. 

With scriptrunner, you can use recursive linking to get the results you want. You find the doc here

For your query, it could look something like this: 

(issueFunction in linkedIssuesOfRecursive("project = 'Production Issues'")
AND
resolution = unresolved)

 

  1. find all issues that are linked to any (open or closed) issue in the project Production issues (the linked issues themselves can be in any project..), and the issues that are linked to those issues, and so on.
  2. the linked tickets themselves must be unresolved

A little warning, if you have very deep linking, this could be a very heavy query. You can use the Limited query to decide how deep down the possible rabbithole you want to go. 

linkedIssuesOfRecursiveLimited(query, depth)

 

Good luck!

Tessa

Suggest an answer

Log in or Sign up to answer