Hi,
I am trying to write JQL that will allow me to select all those Jira tickets for the current active sprint that are not done and excludes certain epic (A-123) and label (XZY).
This is what I have and it is not working.
Project = ABC AND Status != Done AND 'Epic Link' != A-123 OR Labels != XZY
Please help.
Hey, try this:
Project = ABC AND Status != Done AND (('Epic Link' != A-123) OR (Labels != XZY)) AND sprint in openSprints () ORDER by Rank DESC
You had the OR part not but in brackets so it could give weird results - you specify you want issues from active sprints by telling JQL - get me issues in openSprints only :)
Let me know if it works.
Thanks Marta. It did not work as my example had:
So the outcome should have been:
9 issues (out of 12) left to do (12 - 3 = 9) , instead, I got 6 issues left to do....
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
(project = ABC and status != Done and sprint = '<your sprint id>' AND (('Epic Link' != 'A-123') OR (Labels != 'XZY')))
I am surprised that the suggestion from @Marta Woźniak-Semeniuk above didn't work. Looking at your request, I would then search with the above structure.
If you still do not get what you want, then my suspicion is either, you have tickets that you believe match a specific parameter but do not and in this case, searching phase by phase (adding the next set of parameters after validating the prior returns the list of issues expected first) would be the way to go.
Regards.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you @Ismael Jimoh
Jira version I am using, a free version online, converts the query to this and gives the wrong result as mentioned above. It removes the brackets.
I don't add project as it is a quick filter on a Jira board.
status != Done AND sprint in openSprints() AND ("Epic Link" != HTS-5 OR Labels != Client)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
status != Done AND sprint in openSprints() AND ("Epic Link" != HTS-5 AND Labels != Client) ORDER by Rank DESC
try this :)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you again. I did try and it gave me the wrong result. Also the brackets were removed by Jira.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Okay if you are using it as a quick filter for the board then the “sprint in openSprints()” part is obsolete as by default only current sprint tickets are visible.
Then it would leave
“status != Done AND “Epic Link” !=HTS-5 AND labels not in (Client)”
If the above is till giving wrong results, what is wrong with the results - does it show the done tickets too or the problem is with the epic/label?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Safraz,
If this is failing, then it could mean the logic you have in mind and what you expect are not matching.
As we have no access to the tickets, I will go with my original suggestion of adding the next condition after validating that what you currently see is what you expect to see.
The question is which ones are failing. For example, with the current search, you will not get issues where Epic link is empty.
Here is a sample query I built that you can adjust:
project = "Sample scrum project" and Sprint in openSprints() and status != done and (("Epic Link" != SSP-7 or "Epic Link" is EMPTY) or labels != l1)
I had 3 issues, where one had the label mentioned, the other had the epic link mentioned and the 3rd had neither.
I successfully get just one ticket back.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I am using this query as a quick filter:
status != done AND ("Epic Link" != HTS-5 OR "Epic Link" is EMPTY OR labels != Client)
I have:
Should expect:
8 back but getting 10 instead (i.e. Labels are not working)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I think the != for labels might be the issue, there was a thread in the community about it once. Let's try with the
status != done AND ("Epic Link" != HTS-5 OR "Epic Link" is EMPTY OR labels not in (Client))
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Is the Or operation checking if the issues are a part of the epic or are matching the epic.
Use brackets to combine and order operations in the order you want the search to be performed.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Another option would be building your query and validating you have the write list of issues first and then adding the next operator and conditions to filter down further
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey @Ismael Jimoh the epic and the label are used together to isolate this particular vendor, as an example, where I have issues for the vendor epic or sometimes the issue belongs to another epic but has the vendor label to distinguish it.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.