Are you in the loop? Keep up with the latest by making sure you're subscribed to Community Announcements. Just click Watch and select Articles.

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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

How to create filter that will show me the tasks & subtasks for a specific user story

Looking for some help to create a filter that will show me all the child tasks of a specific user story.  I'm trying to use this filter to create a gadget for confluence.  I'm somewhat familiar with how to create simple JQL filters and have created some in the past (using the atlassian community's help!) but for this I've hit a brick wall.  I was hoping I could select a particular "sub-filter" under +More but I haven't found anything that works.  I'm trying to display all of this on a confluence page so that's why creating different boards or dashboards won't really work.  I have several of these I'll need to create for each user story so hence the need to use filters where I can hopefully just change the issue ID in the query and clone the filter for each user story. 

1 answer

0 votes
Bill Sheboy
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.
Oct 31, 2023

Hi @bzekich -- Welcome to the Atlassian Community!

To find the subtasks of an issue, please try JQL like this, substituting in your story's key:

parent = theStoryKey AND issuetype = Sub-task

To learn more about JQL and creating queries like this, please see this free training from Atlassian and the documentation pages:

https://university.atlassian.com/student/path/849533-gain-project-insights-through-jql

https://support.atlassian.com/jira-software-cloud/docs/what-is-advanced-search-in-jira-cloud/

Kind regards,
Bill

Thanks @Bill Sheboy.   I tried as suggested but query is returning no issues found even though there are at least a few linked tasks for this particular story.....   

here is the filter JQL code I am using....

project = XXXX AND issuetype = Task AND status in (Blocked, Done, "In Progress", Rejected, Review, TESTING, "To Do") AND component = XXXX AND parent = XXXX-XXX ORDER BY summary ASC

fyi I've substituted the project name, component name and parent name with XXXX.  I'm using the actual project name, component name and story key in the query itself.

Bill Sheboy
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.
Nov 01, 2023

Your filter is using issueType = Task, but those are not Subtasks.

The out-of-the-box issue hierarchy is: 

  • Epic
    • Story, Task, or Bug
      • Sub-task or Subtask

What you described earlier was looking for Subtasks, and so you may change that part of the query to:

issueType IN (Subtask, Sub-task)

 

However, you also now mention linked issues, which is different than the parent / child relationship of issues.  If this is what you are trying, please try to restate the scenario so we can adjust the query. 

Sorry @Bill Sheboy I forget sometimes that nuance is everything in Jira so forgive me as I stumble through this and try to explain a bit better... 

We are not using the out-of-the-box hierarchy.  Our hierarchy is as follows:

  • Epic
    • Feature
      • Story
        • Task or Bug
          • Subtask

We are linking issues one hierarchy level above so a subtask will be linked as a child of a task, a task is linked as a child of a story, a user story is linked as a child task of a feature, etc.  We are not linking a task all the way back to an epic though a user could obviously see that relationship by simply following the ticket flow on down.

My use case here is that we recently were moved to this new hierarchy.  Previously our stories were actually Epics so it was easy to use gadgets to show the work left to be completed in an epic.  Now that we are using User Stories instead its more difficult to show the work left to be completed.  I'm trying to create a filter that will show me a list of all tasks left to be completed for a particular story.  I will then use a gadget in confluence to have that list available for program stakeholders to review any time.  I'd like to create a filter that would allow me to be able to simply clone the filter, replace the key ID for each story and then create a new gadget to be added to a confluence page.  The team that is actually doing the work itself can use the kanban board so all of this is being done for upper level managers and stakeholders to review any time if needed. 

Hope this helps.....

Bill Sheboy
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.
Nov 01, 2023

Thanks for that additional information on your scenario, and...

As a disclaimer I am not using Premium edition and so cannot test some of the things I may suggest.

If you have any of the marketplace addons which extend the features of JQL, you may want to check how they can help with such queries for the modified hierarchy.  Your Jira Site Admin can help you investigate that.  As you are doing this for a Confluence page, you will also want to investigate if any addons you have work with the page macros to show issues.

If not, you could manually update the saved filters when needed or investigate automating the updates of the filters using automation rules.

Thanks for all of your help @Bill Sheboy

I'll dig around more and ask some more experienced team members if they have any advice on this. 

In case anyone comes across this thread I did find a workaround that should work.  It's more manual and will require labeling each ticket but it is working for me now.  Basically you create a label that helps identify that particular story.  From there you can create a pretty simple filter that pulls together whatever you need and finally drop it onto a confluence page as a filter gadget.  Again it's manual but does work. 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events