Forums

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

JQL for Issues Closed in Specific Sprint

Deleted user February 23, 2022

Hello! I'm trying to run a query that will only return issues closed in a specific sprint.

Example - I have Issue M-50 that was worked on and closed during Sprint 1, and M-100 that was worked on during Sprint 1 and Sprint 2, and closed in Sprint 2.

 

I don't want M-100 to appear in the same query as M-50 because M-50 was closed in Sprint 1 and M-100 was closed in Sprint 2. However, M-100 has a Sprint value for Sprint 1 since it moved across sprints.

2 answers

1 accepted

0 votes
Answer accepted
Svenja Lorenzen
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.
February 23, 2022

Hi @[deleted],

I think you can use the function "closedSprints()". The function searches for Issues that are assigned to a completed Sprint.

To find find all issues that are assigned to a completed sprint try:

sprint in closedSprints("Sprint 1")

Kind regards,

Svenja

Deleted user February 23, 2022

@Svenja Lorenzen that does not seem to work for me. I'm not sure closedSprints() can be used for that. I'm getting the following error.

 

Could not resolve the project 'Sprint 1' provided to function 'closedSprints'.

Svenja Lorenzen
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.
February 23, 2022

Hi @[deleted],

I see. I tried the following query and this one worked for me:

project = XXX AND status = "Done" AND sprint = "Sprint 1" and sprint != "Sprint 2"
Like Ofentse Modisakeng likes this
Deleted user February 23, 2022

Thanks! I had come up with that too but was hoping there was another way in case an issue spanned future sprints as well. I think this is the only way. Appreciate it!

Like Marc Divins Castellví likes this
Ofentse Modisakeng
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 12, 2023

 @[deleted] 

What will be query in  include all statuses in the previous sprint?
My current j-query displays completed or closed issues only?

see eg:  project = YYY AND issuetype in (Story, Sub-task) AND Sprint = #### AND component = DCS AND component = "ZA/DVS" ORDER BY issuetype DESC

0 votes
Slavna Dadic
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!
October 5, 2023

HI @[deleted] i know i am really late to the party - neither of these solutions worked for me but what did work is actually using fixVersion instead. Our setup is that each sprint is separate production deploy and that means separate fix version as well. So when i want to query what was done (closed) in a specific sprint i just use fixVersion = 12345

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events