Forums

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

Hi there, I need help writing a JQL search on scriptrunner

Candice Irwin
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 8, 2023

I need help writing the follow JQL  in scriptrunner please:

 

I need to search project 

Issuetype = Story

Linked Issuetype = Bugs/Defects only

column to show number of bugs open and closed

Fixversion = "V1(Day 1)

Order by labels ASC

1 answer

0 votes
Andrew Wolpers March 14, 2023

Hey Candice, I would suggest using `issueFunction in linkedIssuesOf()`, which would look something like:

issuetype = Story and issueFunction in linkedIssuesOf("issuetype = bug") and fixVersion = "V1(Day 1)" ORDER BY labels ASC

If you're using `Defect` as well you would just update your JQL in the sub query.

 

The column(s) would be dependent on your gadget or filter, but the separation of open and closed issues that are linked to the Story might not be something Jira supports out of the box.  

Candice Irwin
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 15, 2023

Thank you for your help.

When I put this JQL in, I am retrieving all linked issues including "Change Requests", whereas I only want "bugs" listed. Is it also possible to have another cell for each story on number of "bugs" opened and number of "bugs" closed?

Thanks

Candice 

Suggest an answer

Log in or Sign up to answer