Forums

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

Jira filter that shows epics without tasks in sprints

Ali Jacobsen
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 17, 2023

I am using Jira cloud and need a Jira filter that shows me any epics (this is the parent issue) that are "in progress" but do not have any task, story or bugs (these are the children issues) in the current sprint or future sprints.

 

I have already tried the following filter:

issuetype = Epic AND status = "In Progress" AND project IN ("Project Names Here") AND "Epic Link" is EMPTY AND issueFunction not in hasLinkType("blocks") AND issueFunction not in linkedIssuesOf("issuetype in (Task, Story, Bug) AND Sprint in openSprints()") AND issueFunction not in linkedIssuesOf("issuetype in (Task, Story, Bug) AND Sprint in futureSprints()")

I am getting a return of "no results found". I know this is not correct as I added in a test epic that fulfills this criteria.

Thanks for the help!  

1 answer

1 vote
Laurie Sciutti
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 17, 2023

Hi @Ali Jacobsen ~ try this:

issuetype = Epic AND status = "In Progress" AND not issueFunction in linkedIssuesOf("Sprint in openSprints()", "has Epic") AND not issueFunction in linkedIssuesOf("Sprint in futureSprints()", "has Epic")

 

Ali Jacobsen
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 17, 2023

Thank you so much for your response! 

In theory it wants to work, but I have an error message that comes up saying "The "linkedIssuesOf" JQL function provided by "Adaptavist Scriptrunner" for Jira Server works differently in Jira Cloud. Run it directly in "Enhanced Search" instead. See the documentation for more details: https://docs.adaptavist.com/sr4jc/latest/features/scriptrunner-jql-keywords-functions"

Unfortunately my company is not currently subscribing to Enhanced Search. Thoughts on how to work around this obstacle?

Or this obstacle? As I ran it in ScriptRunner to see if it would work and came up with this error:

"Search parsing timed out. You probably have a subquery that returns too many issues"

 So kind of stuck. Thanks again!

Romy Greenfield
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 20, 2023

Hi Ali

You get Enhanced Search included as a feature of ScriptRunner for Jira Cloud, so technically you are already subscribing to the same functionality as Enhanced Search under the ScriptRunner Enhanced Search feature.

When running a query in ScriptRunner Enhanced Search, it can try to process a large amount of issues and this can take a long time. Due to limitations on Cloud, if the request takes more than 30 seconds to process, it will not be able to return results and you get the following error:

"Search parsing timed out. You probably have a subquery that returns too many issues"

A way to avoid this is by trying to be more specific in the jql inside the ScriptRunner Enhanced Search function "linkedIssuesOf".

For example using 

linkedIssuesOf("Sprint in openSprints()", "has Epic")

The first parameter of the linkedIssuesOf function "Sprint in openSprints()", will try to get every open sprint for every project in your instance. If you have hundreds of projects, this will mean getting hundreds of sprints. It will then look at getting all of the issues in all of the open sprints. This could be 1000 issues, if you have 10 issues in each sprint. It will then have to process which issues are linked to those tickets depending on the specified link type. 

Compared to

linkedIssuesOf("project=PROJ1 and Sprint in openSprints()", "has Epic")

This will try and get the open sprints from only one project and therefore, return only 10 issues if there were 10 issues in that sprint.

You can see the order of magnitude of processing has reduced significantly by narrowing down the criteria in the first parameter in the "linkedIssuesOf" function. 

If you need further help, we have a great support team available for ScriptRunner for Jira Cloud customers

Best regards

Romy

Like # people like this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events