Forums

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

JQL to list all tasks under userstories part of the current sprint

Gerrit Deloose
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!
July 24, 2025

Dear,
spent already quite some time scrolling through post but couldn't find perfect match. 

I want to build  JQL which gives me all the tasks under US which are part of the current sprint 

 

'problem' is that tasks re not directly part of a sprint but only userstories are so I'm  bit struggling to get that relationship in my query 

project = XXX and issuetype = task and issue in linkedissuesof (Sprint = 65483 )

gives an exception.

 

any suggestions? (or link to a  proper youtube training on writing JQL?)

 

kind regards,

2 answers

0 votes
Trudy Claspill
Community Champion
July 25, 2025

Hello @Gerrit Deloose 

Welcome to the Atlassian community.

I have a few questions about your statement:

I want to build  JQL which gives me all the tasks under US which are part of the current sprint 

Can you show us a "US" show the "tasks" that are "under" it? I want to make sure I correctly understand the issue type hierarchy you are using.

To find issues that are in a sprint use the syntax:

sprint = <sprint ID>

Refer to the Sprint field documented here in Advanced JQL Searching:

https://confluence.atlassian.com/jirasoftwareserver/advanced-searching-fields-reference-939938743.html

 

If you use a query like this:

project = XXX and issuetype = task and sprint = 123

...then you will get all Task type issues from project XXX that are in the sprint with ID = 123.

 

0 votes
Thorsten Letschert _Decadis AG_
Community Champion
July 25, 2025

Hey @Gerrit Deloose

The default linkedIssues() function does not support subqueries and can only be used with dedicated (single) issue keys.

What you're trying to achieve could be done using an additional app.

Jira Workflow Toolbox, for example, comes with dedicated JQL functions, and a query for your use case might read

project = XXX and issuetype = task and issue in linkedTo("sprint = 123")

using the linkTo() function.

Another app capable of doing this is ScriptRunner, which has a linkedIssuesOf function.

Regards from Germany,
Thorsten

Disclaimer: I'm part of the team behind the first app mentioned.

Suggest an answer

Log in or Sign up to answer