You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
The Atlassian Community can help you and your team get more value out of Atlassian products and practices.
I know this has been asked before but the threads are old and the solutions do not appear to work with current Jira. My goal is simple - I need a JQL filter that shows all the plan items (Stories, Bugs, and Chores) that do not have any Subtasks. JIRA version is 6.4.3 with JIRA Agile 6.7.2. I am not permitted to install any plugins (such as "JQL Tricks").
In theory " hasSubtasks()
" has been native in JIRA for some time, but does not appear to work. Perhaps I am using it wrong? I tried "issue not in hasSubtasks()" as well as "not (issue in hasSubtasks())" and I still get issues with subtasks. Weird thing is "issue not in hasSubtasks()" shows items that have subtasks while "issue in hasSubtasks()" shows nothing. Not one single item. And I know I have some issues with subtasks because they show when I add "not" . Here is the full filter I am experimenting with:
issuetype in (story, chore, bug) AND Sprint in openSprints() AND status != Closed AND issue not in hasSubtasks()
hasSubtask() is not native to JIRA. This is the list of native 6.4 functions. It's available in Scriptrunner with this notation:
issueFunction in hasSubtasks()
Perhaps you have a different plugin? http://www.j-tricks.com/jqlt-subtask-functions.html has a "hasSubtasks()" function with the notation you describe.
That did it! "issueFunction not in hasSubtasks()" is the correct answer. Not sure what "issue not in hasSubtasks()" was doing. Thank you very much!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Solution without a plugin.
Use below query as a Quick Filter from the Board Configuration.
issueFunction not in hasSubtasks() AND issuetype != Sub-task
It will sort out every story, which has No or Zero sub-tasks.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That solution requires the ScriptRunner plugin. Basically $1000 per month just for me to use JQL extensions... That's not going to happen at the current job. Two years ago when I posted this question I apparently wasn't aware we were using ScriptRunner at the old job.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Mike Shkolnik,
Would a no-cost add-on be acceptable? Not sure if there is one but thought I'd clarify before I want digging.
~~Larry Brock
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
project = <project name> AND Sprint = <Sprint Name> AND issuetype in subtaskIssueTypes()
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Then you can use the JQL:
project = <project name> AND issuetype in (Story, Task) AND issuetype not in subTaskIssueTypes()
Thank you Reg Hawkins
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That will select the stories with or without subtasks not the issues with no subtask...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
According to this page, Jira records the issue-subtask relation as "jira_subtask_inward" and "jira_subtask_outward" links.
By using the issue link type field on this page, which was added in Jira Core 8.0, I was able to get all the issues that have subtasks.
issueLinkType = "jira_subtask_outward"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
In latest Jira instance I can select Sub-Tasks as a column in the query. is this what you are looking for? AND Subtask IS EMPTY?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Subtask does not exist:
Subtask IS EMPTY
-> Field 'Subtask' does not exist or you do not have permission to view it.
Subtasks does, but is not searchable:
Subtasks IS EMPTY
-> Field 'Subtasks' is not searchable, it is only sortable.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I've asked support to open a feature request for this to be added as a native function:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Below JQL will help to find Stories which do not have sub-tasks
project = <projectName> AND issuetype = Story and External Issue Id(this will show some alpha numeric like cf***) is EMPTY
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.