How can I find all the Jira where none of the subtasks are assigned to compliance?

John Norman September 12, 2022

I have searched <issueFunction in parentsOf("assignee != SVC_Jira_UserComplia")>.

This search provides a list of all Jira where there is at least one sub-tasks is not assigned to SVC_Jira_UserComplia.  Which is not the result I want.  I want to isolate those Jira where none of the sub-tasks are assigned to SVC_Jira_UserComplia.  Can you help?

1 answer

1 accepted

0 votes
Answer accepted
Harald Seyr
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.
September 12, 2022

Hi @John Norman 

can you check if something like <issueFunction not in parentsOf("assignee = SVC_Jira_UserComplia")> works?

This would return all issues that are not in the list of those issue where at least one subissue is assigned to compliance.

Regards,

Harald

John Norman September 13, 2022

@Harald Seyr Thank you.  I think that was helpful.  This is my whole JQL and I think it is working.  I want to find all the open Jira where our customer field (Is This Compliance Issue) = "Yes" and there aren't any Sub-Tasks assigned to the Compliance Team.  I think I have to do it in two parts.  1) One Search to find all the Jira that don't have sub-tasks, and one to find all the Jira with Sub-Tasks but they aren't assigned to the compliance team.

Here is the second search and I think it is working with your help.

 

<"Is This Compliance Issue" = Yes AND statusCategory !=Done AND status != Withdrawn and issueFunction in hasSubtasks() and issueFunction not in parentsOf("assignee in (SVC_Jira_UserComplia, [add all the employees in compliance])")>

 

The other query would be...

 

<<"Is This Compliance Issue" = Yes AND statusCategory !=Done AND status != Withdrawn and issueFunction not in hasSubtasks()>

 

I think both these work.  I couldn't figure out a way to combine them.  Any ideas on combining them?  Maybe an "or" statement?

Harald Seyr
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.
September 13, 2022

To me, the JQL looks very similar to SQL or a script language, so maybe you try wrapping the two statements in brackets and combine them with an "OR", e.g. like

"(<query 1>) OR (<query 2>)"

In case you want to dig deeper in the features of JQL, you can check the reference at Advanced search reference - JQL operators | Jira Software Cloud | Atlassian Support

Suggest an answer

Log in or Sign up to answer