Hi All,
EDITED: How do I modify the filter below to show only Subtasks & parent Epics of Tasks called "change management task" (tasks should not be visible, only epics & sub-tasks).
project = RRP AND issuetype= task AND text ~"change management task" ORDER BY Rank ASC
Hi,
I think you need something like this,
issue in subTaskOf("project = RRP AND issuetype= task AND text ~ \"change management task\" ") ORDER BY Rank ASC
which is available with Scriptrunner!
Cheers
Then it is unlikely you can achieve what you trying to filter. If you can identify the the keys for those tasks then you may use something like this,
project = RRP AND parent in (<issuekey1>,<issuekey2>,...) ORDER BY Rank ASC
@Cengiz Akyildiz is correct as far as I know that there is no JQL functions out-of-box that let you do this kind of 'nested' or relational querying. The feature request is JRACLOUD-21936 for anyone who wants to add their howls to the void.
However if you are willing to use a custom field and Automation, you could set a flag if\when the parent has "change management task" in the title and search for sub-tasks with the flag set.
If you list down your existing add-ons you have that might with, we can suggest some other solutions using your existing add-ons. As people suggested here automation can help you out to tag your subtasks.
Possible methods for example:
But those are all based on having a custom field that will be set through various automation tools listed here (there are more than you think actually)
But again the simplest way is to have a JQL function that provides you the set of sub-tasks given the nested criteria. Not necessarily SR4J, there might be some other cool add-ons, there are new add-ons coming up on the Marketplace, which you might be able use it for free.
Ooh nice I've just realized MyGroovy support scripted fields also. But you know Jira Server is sunsetting, you gotta test it in DC.
Oh wow I did not know about MyGroovy, but um, this was posted in Jira Cloud Admins, so might not be applicable? :-/
Ooh totally you are right, I forgot for a moment which environment is the issue for.
Hi, Check below if that helps!
#if you multiple parent task with similar summary
project = RRP AND issuetype = Sub-Task AND text ~ \"change management task\"
or
#if you have single parent task number
project = RRP AND issuetype = Sub-Task AND "Parent Link for Task" = "issue-key" AND text ~ \"change management task\"
or
#if you have multiple parent task number
project = RRP AND issuetype = Sub-Task AND "Parent Link for Task" in (issue-key, issue-key) AND text \"change management task\"
it doesn't like the statment project = RRP AND issuetype = Sub-Task AND text ~ \"change management task\"
Hi, it won't be working as you expect either way without some add on for extended JQL queries. In the basic jira query you can not filter subtasks of parent/s defined by another query.
Either You need some add on for it or you need to divide the query to two steps and manually change it always when you need it (not useful for dashboards with automatic updates). The first you need to find all the parent issue with the text - anotation is: text~"change management task", and it will find all the parent issues, you tak list of the found issue keys and make a second query with them in parenthesis: issuetype = Subtask AND parent in (PRP-1, PRP-2...)
Workaround could be use the automation to put labels to the subtasks and than make query based on subtasks issue type and the lable
I think because you are escaping the quotations in your JQL it is taking /"change as a term and expecting another key word after it, try:
project = RRP AND issuetype = Sub-Task AND text ~"change management task"
thank you fot the suggestion, the query will not work because there are no sub-tasks called "change management task"
Hi, Try this:
project = RRP AND issuetype= task AND parent in (issue-key) AND issuetype in (epics, sub-tasks)
replaced (issue-key) with the actual issue id, no issues were found to match the search
yes because this query makes itself never match - you want all issues that are at the same time type "task" and "epics or subtasks", so from that query delete <AND issuetype= task> and epics wont be found with this query, because it wont fit <parent in>, you need to divide search for subtasks and for epics with <OR>
(project = RRP AND parent in (issue-key) AND issuetype = sub-tasks) OR (project = RRP AND parentEpic = (issue-key))
What is the issue key and issue type for "change management task"? I am assuming that the issue type is the parent of the subtasks that you are trying to query on.
Try this:
project = PRP AND issuetype = "Sub-task" and "Parent Link" in (Issue Key)
where Issue Key is the parent issue of the "change management task"
Recommended Learning For You
Level up your skills with Atlassian learning
Learning Path
Jira Administrator
Configure Jira Software, Jira Core, or Jira Service Management, including global settings, permissions, and schemes.
Managing Jira Projects Cloud
Learn to create and configure company-managed projects in Jira Software and partner effectively with Jira Admins.
Learning Path
Become an effective Jira Software Project Admin
This learning path is designed for team leaders who configure Jira Software projects to match a team's processes.