Forums

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

JQL to full all the Stories from Features with a condition

Katrina Atkinson November 7, 2024

I have a filter that pulls all the Features with a certain condition (label applied); how do I then create a JQL that shows me all the stories linked to the features under this filter? 

 

(Enterprise Jira)

2 answers

0 votes
Hannes Obweger - JXL for Jira
Atlassian Partner
November 10, 2024

Hi @Katrina Atkinson

Unfortunately, this is trickier than one might think; as a hierarchical query, it would really require some kind of "join" or "subquery", which isn't available in plain Jira/JQL.

A few directions forward:

  • If it's a one-off thing, you could first query the relevant features, and then use the keys of these features in a second query, in a "parent in (KEY-1, KEY-2, ...)" clause.

If you want to run your search dynamically, without manually "stitching" two queries together, you'll need extra tooling:

  • You might be able to use Jira Automation to "propagate" feature information down to the feature's children, and then use the respective field(s) on the children to include them into your filter. Obviously, this will add a fair bit of complexity to your system.
  • There's different apps from the Atlassian Marketplace that can help with that. First, there's a number of apps that extend JQL by additional functions, including hierarchy-related functions. I've used JQL Search Extensions a few times and it works well.
  • Alternatively, you could try one of the more hierarchy-focused apps from the Marketplace. These apps typically have their own ways of figuring out parent/child relationships between issues, and provide more powerful ways of searching through issue hierarchies. I myself work on such an app, in which your use case would be easy to solve - I'll provide more details below.

Hope this helps,

Best,

Hannes

 

Hannes Obweger - JXL for Jira
Atlassian Partner
November 10, 2024

... and just to expand on the last point: This is how this would look in the app that my team and I are working on, JXL for Jira. Put simply, you'd create a sheet with all issues that are potentially relevant to you, model your issue hierarchy (if you're using the default hierarchy, that's just one click), and then use JXL filtering capabilities to narrow down to the issues that you care about:

epics-for-label.gif

Once you have your list of issues, you can work on these directly in JXL (much like you'd do in e.g. Excel or Google Sheets), trigger various operations in Jira, or export them for further processing.

Any questions just let me know!

0 votes
Trudy Claspill
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 7, 2024

Hello @Katrina Atkinson 

There is not a method to do that with only native Jira JQL functionality.

The portfolioChildIssuesOf() enables you to do that sort of query for one explicitly specified Feature at a time. You can't provide a filter as the input for the Features in that case.

What do you want to do with the results?

A workaround using an Automation Rule could be possible. A Scheduled trigger could use the JQL you have to select the features, and then you can use the portfolioChildIssuesOf() repeatedly to get the child issues of each feature. The results can be sent to users via email.

Otherwise, are you willing to consider a third party app to achieve your requirement?

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events