JQL bug with field Resolution and value Fixed?

Following query works - and lists all the issues for which Resolution is Fixed and Unresolved. (Note: Unresolved shows in italics in the response.)

project = XXX AND  assignee in (YYY) AND status not in (Closed, Done, cancelled )   

Following query also works - shows only those who have resolution as Fixed.

 project = XXX AND  assignee in (YYY) AND status not in (Closed, Done, cancelled )   and resolution in ( Fixed )

To eliminate Fixed ones and see only Unresolved, I modify the query as below - and it DOES NOT WORK!

 project = XXX AND  assignee in (YYY) AND status not in (Closed, Done, cancelled )   and resolution not in ( Fixed )

I also tried the following version - and that too did not work.

project = XXX AND  assignee in (YYY) AND status not in (Closed, Done, cancelled )   and NOT ( resolution in ( Fixed ) )

Am I missing something - or is this a JQL bug?

1 answer

1 accepted

3 votes
Accepted answer

It's not a bug, you are missing something. 

Look at the question you are asking it, and bear in mind that computers are very literal, and do not think the same way humans do, nor do they think in the same language.

When you ask "resolution in x, y", you are asking for all issues where the resolution is either x or y.

When you ask "resolution is not in x, y", you're asking for all issues where the resolution is not x or y. 

But you have not asked for issues where the resolution is empty, which JIRA will report as "unresolved".  You can't ask a computer to check if something is not X or Y when there is nothing there to actually check.  It can't do it.  Humans mostly instinctively understand that <null> in this case also means "not x or y", but mathematically and logically, it's not.

Try this query:

project = XXX AND  assignee in (YYY) AND status not in (Closed, Done, cancelled ) and

(resolution not in ( Fixed ) or resolution is empty)


It should also work for (resolution not in (Fixed) or resolution = unresolved)

 

Thanks much @Nic Brough.

The UI made me completely miss the point that "Unresolved" is actually NULL - and not a literal like Fixed. (When I download the report in Excel, the "unresolved" does come in as empty field though.)

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Tuesday in Statuspage

How do your teams prepare for really high (planned) traffic days like Cyber Monday?

Hi there! Shannon from Statuspage here.  👋  With Cyber Monday quickly approaching, we're looking to hear from Atlassian customers – specifically from teams who touch incident response li...

57 views 0 5
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