I have a list of tasks. Some have sub-tasks. How do I list all tasks omitting the parent tasks? For example:
assignee = currentUser() AND (IS NOT parent)
assignee = currentUser and issuetype in subTaskIssueTypes()
should do the trick. Strictly, it's not what you're really asking, but it will give you the right answer.
To summarize the (above) discussion, what I want can't easily be done with the Jira queries at present.
It looks like a combination of the following two queries could accomplish what I want:
Thank you to @Jack Brickey and @Nic Brough -Adaptavist- for your help on this!
And if you happen to want to include issues without subtasks…
assignee = currentUser and (issuetype in subTaskIssueTypes() OR issueLinkType is EMPTY)
Thank you, Jack!
Getting closer.
Here is the query I'm currently using. It still seems to be missing my top-level stories
assignee = currentUser() and (issuetype in subTaskIssueTypes() OR issueLinkType = EMPTY) AND resolution = Unresolved
Unsure why story 2 would be assigned to you if no action required by you. But that is a horse of a different color.
In any event, you could not achieve the goal with native JQL. Maybe Scriptrunner and Nic can likely assist there if SR is an option.
It looks like you're new here. Sign in or register to get started.