Forums

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

Querying for No Child Issues

Nitin S_ Joshi October 21, 2022 edited

Hello, I have read numerous posts on how to find issues that have no child issues using scriptrunner. None of them work for my use case.

We have an issue hierarchy with Initiatives above. I can query for Epics with no child issues using issuetype = epic AND issueFunction not in hasLinks("is Epic of").  But I cannot do this for the next level up for initiatives with no Epic child issues.

Any ideas without buying an add-on? (BTW, this does not work: type = Initiative AND issuefunction not in linkedIssuesOf("type=initiative", "is child of"))

Thank you.

1 answer

0 votes
Patty Land
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.
October 27, 2022

It looks to me like you're querying the link type in the wrong direction on Initiatives; whereas on Epics you're querying "is Epic of" (top-down), on Initiatives you're querying "is child of" (bottom-up).

type = Initiative AND issuefunction not in linkedIssuesOf("type=initiative", "is child of") is actually querying Initiatives which are not children of other Initiatives. A better query would be:

type = Initiative AND issuefunction not in linkedIssuesOf("type = Epic", "Parent of")

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
atlassian, jira product discovery, jpd premium, product management, idea management, product discovery, jira premium, product planning, atlassian community, product development, roadmap planning, product prioritization, feature management

Introducing Jira Product Discovery Premium ✨

Jira Product Discovery Premium is now available! Get more visibility, control, and support to build products at scale.

Learn more
AUG Leaders

Atlassian Community Events