14

I have to do a little sub-task clean-up and wondering if there is an easier solution to do this using JQL.

Basically i want to find all sub-tasks that are not closed where the parent of that sub-task is closed. Is this possible?

I have tried to google the problem but the majority of the solutions require installation of a plugin which unfortunately i am not able to. Is there an alternative?

My attempt so far:

(project = MYPROJECT        
         AND issuetype = Sub-task 
         AND status in (Open, "In Progress", Reopened, Resolved)
         AND issue in parent(project in ("MYPROJECT")  and status = Closed)
        )

But there is no parent function.

ziggy
  • 15,677
  • 67
  • 194
  • 287

2 Answers2

5

It's not possible with JQL out of the box. But there's a free plugin that allows this. See examples listed here.

The JQL you're looking for should be like this:

type = sub-task and status = Open and issueFunction in subtasksOf("status = closed")

Nuwan
  • 1,226
  • 1
  • 14
  • 38
grdl
  • 3,640
  • 3
  • 21
  • 25
  • 3
    Thanks - I dont have access to add new plugins so that is not possible – ziggy Oct 24 '13 at 15:51
  • 6
    It not free anymore. I suggest https://marketplace.atlassian.com/plugins/com.atlassian.jira.copy-to-subtask-plugin/server/overview Also i feel sad that we bought half-ready product. It's very rude. – Offenso Mar 11 '16 at 13:12
-1

You can use below JQL to trace subtasks of a change request project = CLI AND issuetype = "Change Request" AND status = Completed AND issue in subtask("status != Done")

Here You can change your project to multiple project e.g. project in ("proj1","proj1") AND issuetype = "Change Request" AND status = Completed AND issue in subtask("status != Done")

  • Results in message "Unable to find JQL function 'subtask(status != Done)'." – Simon Jan 24 '22 at 09:18
  • Downvoted until more context is given because this query doesn't work in my current Jira setup. A quick Google search seems to indicated that a "JQL Tricks Plugin" (for cloud) exists, but no way to be sure. – JBert Jul 01 '22 at 11:38