Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

JQL query help with Initiatives and subtasks

This the jql query I have, this shows all the canceled initiatives but also want to display the initiatives that are in progress that have a sub task canceled but not show the canceled subtask just the initiative in progress with the canceled subtask. 

project in (A, B) and issuetype in (A-Initiative, "B Initiative") and status in (Canceled)

2 answers

0 votes
Rachel Wright Community Leader Jun 15, 2021

Hi @Joe , if I'm understanding your correctly, you're looking for some kind of "nested" or "cascading" JQL query, right?  ("Find issues that are related to other issues, where the other issues have a certain status.")  If so, there's no built in way to do this.  There may be a way provided by an app from the Atlassian Marketplace.

I once did this using a script someone wrote using the REST API and promptly crashed my entire Jira server instance!  Not a fun day.  So be careful if you try to get creative with the REST API.

One thing you could do is create a dashboard of all your initiatives, and include the "Sub-tasks" or "Linked Issues" columns.  Then you can visually detect this condition.  Any "Resolved" issues will display as crossed out.

Sorry I don't have a better answer for you!

Cheers,

Rachel Wright
Author, Jira Strategy Admin Workbook

@Rachel Wright How would the dashboard be created? I tried rich filter results and rich filter two dimensional statistics. 

Rachel Wright Community Leader Jun 16, 2021

Hi @Joe , you can use the standard "Filter Results" gadget and simply show the "Sub-Tasks" column.  Here's an example:

example-for-joe.png

You can scan through the list visually and see that since DEMO-37 is crossed out ("resolved") then it's parent issue, DEMO-1, meets the condition you were trying to query for.

Click the "..." icon on the top right of the individual gadget to add and remove columns.

Hope this helps!

Rachel Wright

Hi Joe,
With standard JQL you can only do some basic search

Standard JQL doesn't easily allow it but the results can be quickly found using our professional indexing service JQL Search Extensions.

To find active initiatives with cancelled epics:

issue in parentsOfIssuesInQuery("status=Cancelled") and type=Initiative and resolution is empty

To find active initiatives with any cancelled tickets in the hierarchy tree:

issue in parentsOfIssuesInQueryRecursive("status=Cancelled") and type=Initiative and resolution is empty

You can check out our docs for more information.

I hope this helps!
JQL Dan

Suggest an answer

Log in or Sign up to answer
TAGS

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you