Jira JQL for issue on different project
Asked by Erik Boneschansker:

Hello there,  

Im not that good with Jira JQL but i have a question.  
We would like to have a que in our servicedesk project that is showing tickets older then 7 days, which have not been updated (off a different project, that are linked issues).

So we have an ITSD en WBENG board.

I now have this:  

status = "Waiting for change" AND "Solution group" in (Engineering, "Applicatiebeheer Afas", "Cyber Security", Development, "Development Bridge", "Development Support Walfis", "IT KNS", "Nedlift functional management") AND updated \<= -7d AND status != Resolved AND status != Closed  

Which works, but only for the project that we are in (ITSD) but I also want this rule to check the linked issues in all of the solution groups.

Thanks in advance


Answers:
author: Trudy Claspill
body: Hello [@Erik Boneschansker](/t5/user/viewprofilepage/user-id/3796744)

Can you clarify this point...

Your service desk project is "ITSD". In its issues you have links to other issues. Are those other issues also in the ITSD project or are they in a different project?

Do you want to display the other, linked issues in your ITSD project queues?

Or are you trying to base the selection of the ITSD issue on criteria that you want applied to the linked issues?

You mentioned wanting the query to "check the linked issues in all of the solution groups". And in the query "Solution group" appears to be a custom field, perhaps a single or multiple selection list field.

In your query you are referencing the **status** field multiple times in a manner that is unnecessary.

**status = "Waiting for change"** AND "Solution group" in (Engineering, "Applicatiebeheer Afas", "Cyber Security", Development, "Development Bridge", "Development Support Walfis", "IT KNS", "Nedlift functional management") AND updated \<= -7d **AND status != Resolved AND status != Closed**

An issue can have only one Status value. The first criteria selects issues based on the Status field being equal to a specific value. If that criteria is met then the two criteria at the end are irrelevant.

**status = "Waiting for change"**

**status != Resolved AND status != Closed**

If the Status is "Waiting for change" then clearly the status is already not "Resolved" and not "Closed"

Perhaps I am misunderstanding what you are trying to accomplish.

Can you perhaps provide some example issue data of ITSD issues and linked issues, with information about their status values, Solution group values and Updated values, and explain which issues you would expect to have in your results set?

comments: author: Erik Boneschansker
body: Hello [@Trudy Claspill](/t5/user/viewprofilepage/user-id/3569011) Trudy, thanks for helping me out.

*Your service desk project is "ITSD". In its issues you have links to other issues. Are those other issues also in the ITSD project or are they in a different project?*

ITSD is our servicedesk project/board which has linked issues to WBENG which is an different project in our Jira.  

example: itsd-1234 has a linked issue to wbeng-1234 (ticket both excist)  

My goal is to make a que, to see if someone made a comment or did something active with the WBENG (linked issue) ticket.   

Now we manually check the tickets and thats a pain.


author: Trudy Claspill
body: Hello [@Erik Boneschansker](/t5/user/viewprofilepage/user-id/3796744)

If you want to show in the ITSD project queues the details of WBENG issues, that will not be possible.

If you want to show an ITSD project queue that lists ITSD tickets, where those tickets are linked to a WBENG issue, and further constrain the list of ITSD tickets by applying criteria to the linked WBENG tickets, that **may** be possible with a third party app. It would not be possible with only the native Jira JQL capabilities.


author: Erik Boneschansker
body: Thanks Trudy,  

For now I will leave the post open to see if others might have an idea.  

(Its not about the details)

I don't want to see the input of the linked issue, i just want to see if the status is changed or these is a comment added. (and not litterly see the comment)

Just a que that gives a sign that the linked ticket is changed


author: Trudy Claspill
body: If you want a queue that lists ITSD issues where the status of a linked issue has changed or a comment has been added to a linked issue in the past X days, there are two ways you can achieve that.

1. Acquire a third party app that will extend JQL capabilities that will enable you to execute filters for issues based on changes to linked issues.

2. Create Automation Rules that will update the ITSD issues when specific changes occur in the issues linked to them. For instance, you could keep a custom date field in the ITSD issue. You could create an Automation Rule that is triggered when a comment is added to a WBENG issue. In that rule you would check to see if that WBENG issue was linked to an ITSD issue. If it was, then in the rule you would update the custom date field in the ITSD issue. Then your Queue filter could look for ITSD issues with that custom date field within (or outside of) your specified date range. You could create a similar rule for when the Status changes on a WBENG issue.


Tags: cloud

jira-service-management

jira-service-management-cloud