Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Need help with JQL: Looking for a list of Stories where only bugs have been linked to

I need help with JQL. I am not a programmer. I do not have access to the backend to configure JIRA. 

I am looking for a way to pull Stories with linked Bugs only. 

sample: project = <my project> AND issuetype = Story AND status = Accepted

I have a column Links, however, it shows me everything that is linked but I only want to get a list with bugs. 

If there is no way to do this with JQL filter, can it be done in Project Automation where it can send the report with all Stories linked to bugs once a week? 

Thank you!

Diana 

2 answers

2 accepted

0 votes
Answer accepted
Robert Wen Community Leader Dec 03, 2021

Hello @Diana Leon !

The closest I can come to what you want is this (using OOTB JQL):

project = <my project> AND issue type = Story AND issueLinkType = "is blocked by"

This will only work if you consistently set up this link relationship to your Bugs.  If not, the following variation may help:

project = <my project> AND issue type = Story AND issueLinkType in ( "is blocked by", <other link relationships>)

Hi Robert. Let me try your solution. Thank you!

However, it will pull everything and not just bugs. 

Robert Wen Community Leader Dec 03, 2021

Diana,

You are correct.  it will pull all issues of any type that has that link relationship.

@Joseph Hani may have the better solution, but it will require an app like ScriptRunner.

Like Diana Leon likes this

We do not have ScriptRunner. I doubt it will be allowed to enable in our JIRA. Thank you so much for all your help @Robert Wen and @Joseph Hani .

0 votes
Answer accepted

Hello @Diana Leon ,

If I remember correctly this is not possible with Standard feature of Jira. You will need and extension to do this. Like ScriptRunner or JQL Search Extension for Jira 

Actually the only thing you could get is the issue link from a specific IssueType, for example : 

issue in linkedIssues("TYPI-35")

 

If you have admin rights, and have managed to put all your bug inside a reference like "related to", "approve by", blocks, cloned by, ... (you can check you reference if you are Admin, go to Issues --> under Issue Features --> Issue linking)

Something like this could be useful : 

issue in linkedIssues("TYPI-345", blocks)

 

I would suggest also to try something like this with multiple ticket, but probably need more permissions to do it : 

issueFunction in linkedIssueOf("issue in (TYPI-30802,TYPI-31247,TYPI-30292,TYPI-31270)") AND type in (bug)

 

 

Using an app you could have use something like this , but not working on Standard sorry :/ 

type = Bug AND issue IN linkedIssuesOf("type = Story") 

 

Good luck ;) 

Thank you so much! 

It worked. I have tried: project = <my project> AND issuetype = Bug AND issueFunction in linkedIssuesOf("Type = Story")

Thanks a ton!

Like Joseph Hani likes this

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Apps & Integrations

Send an Email or Publish to Confluence - What should you do with your release notes?

Background When you hear the words ‘Release notes’, almost always you think of an unsolicited email from a software vendor. But I am here to tell you that from our data, sending release notes via E...

61 views 0 1
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you