Forums

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

Sprint Query to find Subtasks Not working

JasonB3 August 30, 2020

I was trying to solve my issue in Sprint Automation trigger for Sub Tasks, when I came across another issue. I'm not sure if this is related. It exhibits similar behaviour. 

 

I'm trying to execute the following JQL (test case 1):

type = subtask AND status != Done AND sprint is not EMPTY

      The results is "No Issues found to match".  This is incorrect, I have subtasks that match this condition. 

 

But if I run (test case 2):

type = subtask AND status != Done 

       The results come back with subtasks with empty sprints and any sprint.

If I run (test case 3):

type = subtask AND sprint is not EMPTY

       The results will come back with subtasks with only empty sprints and any status. 

 

Now this is truly strange. How can the bottom two test cases be correct and not the first one?

 

If this was SQL, i would say there is some sort of JOIN between status and sprint that isn't working. 

 

Can anyone else repro? I'm using Jira Software Online, on a Next Gen Project.

1 answer

0 votes
Bill Sheboy
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.
August 31, 2020

Hi @JasonB3 

Of note: JQL is not an actual SQL (ISO or otherwise).  It appears to be a subset of a query language solely for the purpose of filtering for boards and reports.

Are you certain about the issue type you are using? For example, what do you see when you try this query instead, substituting your project name for myProject:

project = myProject
AND issueType IN (Subtask, Sub-task)
AND status != Done
AND sprint IS NOT EMPTY

 

Best regards,

Bill

JasonB3 August 31, 2020

Hi @Bill Sheboy 

 Changing project to my team's project, and running your suggestion. I get no results.  

 To prove the there are subtasks with sprints, I run (test case 4):

project = myProject
AND issueType IN (Subtask, Sub-task)
AND status != Done

      And its true, I get issues with and without sprints. 

 Interestingly, If I run (test case 5):

project = myProject
AND issueType IN (Subtask, Sub-task)
AND status != Done
AND sprint IS EMPTY

       I get the same result set as test case 4. 

 

We might be getting somewhere. This indicates there might be just an issue with the sprint column.

I've had a run-in in a past Jira Next Gen issue where Story Points were actually called Story Point Estimates in the code but the presentation layer simply called it Story Point

Maybe to get to the "right" sprint for subtasks, I need to use a different property?

Bill Sheboy
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.
August 31, 2020

Nope, you are off track on the story points issue.  For NextGen, they decided to use a different field.  It is not a naming issue; it is a design choice.  ;^)

For NextGen, I recall that each project also uses its own status values.  So, let's go more generic and try the category of the status to see what you get:

project = myProject
AND issueType IN (Subtask, Sub-task)
AND statusCategory != Done
Bill Sheboy
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.
August 31, 2020 edited

Hey @JasonB3 

I just found two open defects that could be what you are facing, as it appears the subtasks cannot be consistently accessed via JQL for a Next-Gen project.  Please check these two defect to confirm how they align with what you are seeing:

https://jira.atlassian.com/browse/JSWCLOUD-18398

https://jira.atlassian.com/browse/JSWCLOUD-18461

JasonB3 August 31, 2020 edited

Just saw your follow-up response.. re-editing my comment.

Yes. It looks like those bugs would be very closely related. 

It says these are in Long Term Backlog. Created almost a year ago :( 

 

I voted up, but is there anything else i can do to help bump this up in the rankings?

 

Bill Sheboy
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.
August 31, 2020 edited

Probably not, although given this is Next-Gen it could get focus sooner.  I've found good ideas and defects in the public backlog for JIRA that are 15+ years old!  As always there are more good ideas than capacity to implement them.

You could try to fill in the feedback form on the JIRA UI, and select the box to join the research group to see if that helps with being heard.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Product Admin
TAGS
atlassian, atlassian government cloud, fedramp, webinar, register for webinar, atlassian cloud webinar, fedramp moderate offering, work faster with cloud

Unlocking the future with Atlassian Government Cloud ☁️

Atlassian Government Cloud has achieved FedRAMP Authorization at the Moderate level! Join our webinar to learn how you can accelerate mission success and move work forward faster in cloud, all while ensuring your critical data is secure.

Register Now
AUG Leaders

Atlassian Community Events