I'm looking to use a JQL query for an issue matrix custom field on a custom issue type called an Initiative. The Initiatives are being used for Epic buckets and were wondering how to filter for all of the issues in the Epics the are connected to the Initiative by "has Initiative" link. We are using the 7.13 version of Jira.
You'll need an app to get JQL to do this. ScriptRunner has this. If you search the marketplace for JQL you'll find others that enhance the search functions.
We have ScriptRunner installed. Is there a particular search function I should look for?
Perfect! Use issuesInEpics in combination with hasLinkType
I think two filters would work best, so first get your epics with the has initiative link type, then use issuesInEpics and call on that filter, eg
issuefunction in issuesInEpics("filter = 'has initiative epics'")
That worked perfectly! Thank you so much @Majken Longlade !!!
Hello Mattew and Majken,Just to let you know, as an alternative method to Script Runner for Jira.You can achieve the same query by using i.e. JQL Booster Pack
issue IN issuesInEpics(' type = Epic AND issue IN hasLinks("> 0", "has Initiative") ')
hasLinks(
"> 0"
,
"has Initiative"
) '
Note that this is just an example, you must tune above query to fit your needs
Using this app you can also query other issues relations, check:
References:
Hope this helps you to create awesome queries
Kind regards
you can use JQL Search Extensions for Jira & reports and it will help you to get the required results.
following query will get all issues and even their subtaks where issue type is initiative and linked to any epic.
issue in allIssuesInEpic("type=initiative")
It looks like you're new here. Sign in or register to get started.