Question in "issue in haslinks" query

I have 2 projects "project1" and "project2"

A bug in project1 is marked with "is blocked by" bug in project2. I want to write a query that captures this. 

When I run this query 

project = project1 AND issue in hasLinks("is blocked by", "project = project2") 

I dont get any results but i am expecting this 1 bug to show up. Why is this query not able to find the linked bug in the other project. What query can I run to accomplish what i am looking for ?

2 answers

0 vote

You still need to have both projects selected - by using "project = project1 and...", you specifically exclude anything that does not meet that condition.

 

project in (project1, project2) AND issue in hasLinks("is blocked by", "project = project2") 

Hi, When I run your query, my result set contains all bugs from Project2. this is good but some of those bugs have "is blocked by" pointing to project1 and some have "is blocked by" pointing to project2. So how do I show up only bugs that has links pointing to project2 ?

0 vote

When you run

issue in hasLinks("is blocked by", "project = project2") 

it retrieves issues in project 2 that has "is blocked by" links. It looks like you are searching for the other scenario. Can you try the following?

project = project2 AND issue in hasLinks("is blocked by", "project = project1") 

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Julia Dillon
Posted Tuesday in Jira

Tell us how your team runs on Jira!

Hey Atlassian Community! Today we are launching a bunch of customer stories about the amazing work teams, like Dropbox and Twilio, are doing with Jira. You can check out the stories here. The thi...

704 views 1 18
Join discussion

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you