Forums

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

JQL for finding Epics

Gor Greyan
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.
September 11, 2025

Hi, Dear colleagues,

I couldn't write a JQL, that will find epics, that don't have linked issues and don't have issue in epics.
Could you please help?

2 answers

0 votes
Trudy Claspill
Community Champion
September 11, 2025

Hello @Gor Greyan 

Having linked issues and having child issues are two different things.

If you want to find Epics that have no linked issues you could try the ScriptRunner hasLinks() function.

https://docs.adaptavist.com/sr4js/latest/features/jql-functions/included-jql-functions/issue-links#find-issues-with-links-haslinks

issuetype = Epic and issueFunction not in hasLInks()

 

If you want to find Epics that have no children you can try this query that uses the epicsOf() function.

https://docs.adaptavist.com/sr4js/latest/features/jql-functions/included-jql-functions/issue-links#find-epics-of-a-subquery-epicsof

issuetype=Epc and issueFunction not in epicsOf("issuetype in standardIssueTypes()")

 

I don't have a data center environment where I can test those out, but logically they should work. However, the ScriptRunner functions will return a LOT of results (if you have many issues in your instance) so these may be processor intensive queries. You may be able to reduce the load by adding more criteria to reduce the number of issues returned by the ScriptRunner functions.

0 votes
Jack Brickey
Community Champion
September 11, 2025

Hi @Gor Greyan , unfortunately there isn't a JQL to find issues without children. You will need a third party app for that, e.g. Scriptrunner or similar.

Gor Greyan
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.
September 11, 2025

Hi, @Jack Brickey

I have Scriptrunner.
Could you please help through that?

Jack Brickey
Community Champion
September 11, 2025

Hi @Gor Greyan , I don't have access to Scriptrunner currently in order to test out a solution. However, there are community posts that should help with this. Also I came across this article that describes a workaround solution that leverages automation. I started to suggest this but if you have Scriptrunner I would go that direction.

also check out Scriptrunner docs

Suggest an answer

Log in or Sign up to answer