How to I get a list of Epics that have Issues linked to them?

I have a SCRUM Board meant to view the current Sprints across an entire department. The goals are the following.

  • Display all Issues currently in Sprints from the relevant Projects in the Plan tab of the SCRUM Board.
  • Have the Epics on the left side of the board displayed if and only if they have Issues in the active Sprints that are linked to them.

First, I just grabbed the Issues.

project in (many many projects) AND issuetype in standardIssueTypes() AND Sprint in openSprints() ORDER BY Rank

Because Epics aren't embedded in Sprints, this left the Epics out. So I explictly grabbed the Epics.

project in (many many projects) AND (issuetype in standardIssueTypes() OR issuetype = Epic) AND Sprint in openSprints() ORDER BY Rank

This pulled in every single Epic ever made. I then tried to limit the Epic selection, though I knew this was too blunt a tool to deal with the teams' abandoned, unclosed, orphaned, and neglected epics.

project in (many many projects) AND issuetype in standardIssueTypes() AND (Sprint in openSprints() OR (issuetype = Epic AND updated > -6w))  ORDER BY Rank

How do I get only the Epics that are linked to from Issues in the current Sprint?

3 answers

Hey Nik,

Sorry about this quick answer without reading through your entire question. But have you tried

https://confluence.atlassian.com/display/JIRA/Advanced+Searching#AdvancedSearching-Sprint

and https://confluence.atlassian.com/display/JIRA/Advanced+Searching#AdvancedSearching-EpicLink

sprint = "xxxx" and "Epic Link" = Something

Sorry, Bhushan, but this won't fix my issue.

Your solution would only work for pulling Stories (or other Issues linked to Epics). This is not what I want. I want to pull Epics that have (1) have links to them from (2) Issues in the current Sprint. (I can get the "current sprint", but saying…

Sprint = openSprints()

. The challenge remains the Epics.

0 votes

> How do I get only the Epics that are linked to from Issues in the current Sprint?

If you can use Script Runner, there are functions and some examples that might help here: https://jamieechlin.atlassian.net/wiki/display/GRV/Scripted+JQL+Functions#ScriptedJQLFunctions-MoreComplexExamples
You can filter further on the current sprint ID.

Hi. Script Runner is not available for OnDemand instances, is there anything we can do to get the same result: "get the issues Epic type from other issues that have them in the Epic link"? Thak you.

I have never used it but there is https://marketplace.atlassian.com/plugins/jql-pro. Seems to create a bit of a disconnected experience, although that's no fault of the plugin.

Any update on this?  This would be extremely helpful for us too (using OnDemand) and I can't figure out a way to do this

Hi!

I've tried to find a solution for this myself as well. And I did, at least for my application and intended use. 

You need to have ScriptRunner! 

And in ScriptRunner I used the epicsOf() function like so:

 project = MyProject AND issueFunction in epicsOf('"Backlog" = "MyBacklog" AND Status in ("Ready for Backlog", "In Progress", "Ready For Verification", "Under Verification", "Resolved")')

This enabled me to filter out Epics for my backlog that were relevant to ongoing tasks, thus using the "Epics" window in the backlog properly without any irrelevant Epics.

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,991 views 12 18
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot