Forums

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

Getting tasks, subtasks, and subtasks under tasks under epic to show in search

Austin Green
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 15, 2021

How to create a search that returns every task in an epic and every subtask of every task of that epic.

I want to see 

-epic

--task linked to epic

---subtask of task linked to epic

---subtask of task linked to epic

---subtask of task linked to epic

--task linked to epic

---subtask of task linked to epic

--task linked to epic

---subtask of task linked to epic

---subtask of task linked to epic

--Epic subtask

--Epic subtask

3 answers

1 accepted

0 votes
Answer accepted
Pramodh M
Community Champion
January 15, 2021

 

For Linked Issues:

issue in linkedIssues(issueKey,linkType)
For Task linked to Epic: 

project = "projectKey" AND "Epic Link" = issueKey AND issuetype = Task
Subtask of Task linked to Epic

Since Sub-Tasks follow the Syntax parent = issueKey or parent in ("issueKey-1, issueKey2 ")

I guess it's not possible to retrieve the Subtask of Task linked to Epic from JQL

You can't have Sub-Task for Epic

Thanks,
Pramodh

Pramodh M
Community Champion
January 15, 2021

FYI

The Subtask of Task linked to Epic is possible with add-ons and please follow the link for more info..
https://community.atlassian.com/t5/Jira-questions/How-do-I-get-subtask-to-return-with-parent-issue-in-issue-search/qaq-p/1011160

Pramodh M
Community Champion
January 15, 2021

FYI,

For subtasks of all tasks under a Epic

project = "projectKey" AND ("Epic Link" = issueKey or parentEpic= issueKey)

Will return all subtasks and tasks under a epic.

0 votes
Paul O
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.
January 16, 2021

For the example you give, you just need:

parentEPIC = <your epic>

This will return the EPIC and ALL its contents.

The same results will be returned by

linkedIssue = <your epic> 

(As noted above. EPICs don't have sub-tasks; tasks have sub-tasks)

 

Using "EPIC Link" = <your epic> will return the contents of the epic excluding sub-tasks.

 

Finding 'linked' issues i.e. those not part of the parent -> child hierarchy (EPIC -> Task -> Sub-task) but linked via 'blocks', 'duplicates' etc requires the use of:

issue in linkedIssues("<issue key>")

 

See: https://support.atlassian.com/jira-software-cloud/docs/advanced-search-reference-jql-functions/ for details

0 votes
Carlos Garcia Navarro
Community Champion
January 15, 2021

Hello @Austin Green 

project = "<you_project_here>" AND ("Epic Link" = <your_epic_here> OR parentEpic in (<your_epic_here>) )ORDER BY Rank ASC

"Epic Link" gives you stories or tasks in the Epic, while "parentEpic" gives you the subtasks linked to a story or task for that specific Epic.

Austin Green
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 19, 2021

parent epic is not an option for me

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
8.5.7
TAGS
AUG Leaders

Atlassian Community Events