How do I find bugs with no links?

Sandy Lyons August 14, 2013

I'm using the Greenhopper Scrum board to group sprint items into swimlanes by story (using JQL queries to group them), on AOD.

I want to group all the bugs that are not linked to stories within my sprint into a Bugs swimlane so they aren't under the 'Everything Else' swimlane - there are other items in that such as tasks and improvements not currently related to stories.

Is this possible via JQL? I don't seem to be able to do a catch-all JQL query for issues that have no links - along the lines of "issuelinks is empty" or "issuelinks is null"

Being able to say "issuetype=bug and ISSUE is not linked" would be nice. Is there some way to do this on AOD at the moment?

3 answers

2 votes
Błażej O_
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 15, 2013

If you have groovy script runner it has few really usefull JQL functions. hasLinks is one of them :)

Unfortunately you can pass only one link type to this function so the JQL for this would be:

issuetype = Bug and issueFunction not in hasLinkType("Blocks") and issueFunction not in hasLinkType("Cloners") and issueFunction not in hasLinkType("Relates") and issueFunction not in hasLinkType("Duplicate") and issueFunction not in hasLinkType("Epic-Story Link")

Of course if you have more link types you will have to add them to the query to make sure the issue doesn't have ANY of the link types.

Udo Brand
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 15, 2013

The question is about JIRA Ondemand. So you can't use groovy script runner.

Błażej O_
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 15, 2013

Indeed, my bad. I haven't noticed the tag.

JamieA
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 15, 2013

Thanks for the mention Blazej. But yes, afaik this is not possible in AOD.

0 votes
Tom Haraldsen August 15, 2013

... or

issuetype = bug and issuetype in standardIssueTypes()

to avoid subTaskIssueTypes()

... not tested.

Udo Brand
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 15, 2013

Hmm, I doubt this function "standardIssueTypes()" exists in standard JQL.

But even if it would exists:

If bug is a standard issuetype your query would give you all bugs with or without linked issues.

If bug is a subtask issue type your query would show nothing.

Tom Haraldsen August 15, 2013

Agree in your conclusion:-) Sorry!

... but the "standardIssueTypes()" exist.

Try typing "issuetype in "

Udo Brand
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 15, 2013

Ah, you are right, but I could not find it in the documentation.

Sandy Lyons August 21, 2013

Still searching for a solution to this, if anyone has any other suggestions. Thanks for the efforts so far everyone!

0 votes
Udo Brand
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 15, 2013

Hi Sandy,

I just found in the Advanced Search Documention following solution

issuetype =Bug and issuekey not in linkissues()

I haven't tried it yet, but it should work.

EDIT:

I tried it now and it is not working. The function linkissues() requires an issue key as parameter.

So I have to change my answer into: No, there is no way to achieve this in Ondemand.

Sorry!

Cheers, Udo

Suggest an answer

Log in or Sign up to answer