Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Jira Filter with "parent in"

Hansi January 26, 2018

Hello!

 

I want to create a filter for subtasks.

 

List all not closed Sub-Task of an project that belongs to a specified Filter.

 

The Subtasks:

project = ITSD AND issuetype = Sub-task AND status in ("In Progress", "To Do")

 

The Parent: 

project = ITSD AND issuetype = "Service Request" AND status in (Open, "in Arbeit", "Wartet auf Genehmigung", Auslieferung) AND (ITSD-Anfragetyp-Helper = "Server bestellen")

 

how can I do this?

I have tried something like this:

project = ITSD AND issuetype = Sub-task AND status in ("In Progress", "To Do") AND parent in childIssuesOf("project = ITSD AND issuetype = 'Service Request'")

I will get: Unable to find an issue with matching key project = ITSD AND issuetype = 'Service Request'

rg

hansi

4 answers

1 accepted

0 votes
Answer accepted
Thomas Schlegel
Community Champion
January 26, 2018

Hi Hansi,

do you have the Scriptrunner app? If so, you can do something like that:

project = ITSD AND issuetype = Sub-task AND status in ("In Progress", "To Do") AND issueFunction in subtasksOf("project = ITSD AND issuetype = 'Service Request' AND status in (Open, 'in Arbeit', 'Wartet auf Genehmigung', Auslieferung) AND (ITSD-Anfragetyp-Helper = '
'Server bestellen')")

Thomas Schlegel
Community Champion
January 26, 2018

with plain Jira, you can't have subqueries like in SQL

Like minuk_park likes this
Hansi January 29, 2018

Hello!

thank you for help! I got it.

rg

hansi

Chandrakanth Gangaram
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
March 7, 2019

Hi Hansi,

 

Can you please share how you had combined both the queries?

Like Matthias likes this
0 votes
Isaiah John August 11, 2023

Guys, I just learned you can use the "scheduled" trigger to do a JQL Query. All issues returned will be treated as trigger issues. You could then use the "For: Sub-tasks" branch then a status condition to act on their sub-tasks.

Screenshot 2023-08-11 094501.png

0 votes
Preethi Ramesh
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
April 1, 2019

I was trying to exclude all subtasks from a specific parent key and used the below query. Worked for me. 

assignee in (<jira usernames>) AND status not in (Closed, Done, Complete, Resolved, Cancelled) AND project not in (<give project names that you would like to exclude>) AND  parent != <which ever parent key you would like to exclude> 

This query removed all the subtasks for the parent key

0 votes
Hansi January 26, 2018

thank you for answer!

yes Scriptrunner app is installed.

I will check next week on monday.

 

rg

hansi

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events