JQL search - Stories with parentEpic in a specified fixVersion

Michael Bevilacqua May 16, 2023

Hi,

Id like a filter that gives me all Story issues with an Epic parent containing the version "2023H1".  Is this possible?

so a JQL query could look like this:

parentEpic in (fixVersion = 2023H1Target)
AND issuetype in ("Story")

 

Thanks!

Michael

5 answers

1 vote
mauricio.groth
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.
May 16, 2023

Hi @Michael Bevilacqua

I’m Maurício, a support engineer at Appfire and I’m here to help you.

Unfortunately, using JQL of Jira, you’ll not be able to do it dynamically.

In the app where my team works, JQL Search Extensions for Jira, you can use this query to find all stories with an Epic parent containing the version "2023H1”:

issue in childrenOfEpicsInQuery("fixVersion= '2023H1Target'") AND type = Story

Please contact our support if you have any other questions about this query.

We’ll be happy to help you!

Best regards,

Maurício

Michael Bevilacqua May 16, 2023

Thank you for responding Mauricio, this appears to work yet the plugin cost may be prohibitive for us to use for simply this function.

1 vote
JM Perrot
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 16, 2023

Hi @Michael Bevilacqua 

Can you try issuetype = story AND fixVersion = 2023H1 AND "Epic Link" is not EMPTY

Michael Bevilacqua May 16, 2023

Thank you for the info, yet neither of those JQL queries work since the fixVersion is assigned to the Epic.

JM Perrot
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 17, 2023

OK maybe you have to build your filter step by step

For example the query "fixVersion = 2023H1" works ?

Michael Bevilacqua May 17, 2023

Yes, the query "fixVersion = 2023H1" works. Am I able to combine that query result into another query like:

parentEpic in (queryFixVersion2023H1)
AND issuetype in ("Story")

JM Perrot
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 18, 2023

In theory there is no problem. I'm just suspicious about "parentEpic in (queryFixVersion2023H1)".

In fact you would stories (not necessary in this fix version) but with a parent in this fix version, right ?

0 votes
Hannes Obweger - JXL for Jira
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
May 17, 2023

Hi @Michael Bevilacqua

unfortunately, this is a tricky one; as a "hierarchical query", it would really require some kind of "join" or "subquery", which isn't available in "plain" JQL. To the best of my knowledge, you'll need extra tooling for this. 

A few directions forward:

  • You should be able to use Jira Automation to "propagate" an epic's version(s) down to the epic's children, and then use the respective field on the children to include them into your filter.
  • 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. @mauricio.groth already provided a solution for JQL Search Extensions; I've used the app a few times and it works great.
  • 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 defining and 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
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
May 17, 2023

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, enable the default issue hierarchy (that's just one click), and then use JXL filtering capabilities to narrow down to the issues that you care about:

epics-by-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,

Best,

Hannes

0 votes
Michael Bevilacqua May 16, 2023

x

0 votes
Somnath Patil
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.
May 16, 2023

Hi @Michael Bevilacqua ,

 

Try this JQL : issuetype = Story and "Epic Link" is not EMPTY AND fixVersion = "2023H1"

Michael Bevilacqua May 16, 2023

Thank you for the info, yet neither of those JQL queries work since the fixVersion is assigned to the Epic.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events