JQL query to find a linked issue in another project - jira

I am looking for the Jira JQL syntax to find issues that have a linked issue in another project. For example in three projects I can find the list of issues that have been resolved in the last 90 days. I would like to find a list of issues in our QA project for the original issues resolved list.

sqluser was close. You don't to have designate a single issuekey, if you use the scriptrunner addon. I don't think there is a way around having it. Up to a recent version it was free so you can simply download that version. It's a must have plugin imho. Here is your query:
issueFunction in linkedIssuesOf('resolutiondate > 2015-10-01') and project = QA
You can extend the criteria of the search. Here is the documentation.

Try this plugin:
http://www.j-tricks.com/jql-tricks-plugin.html
specifically JQL function
linkedIssuesInProject(project,[linkType])
but the plugin is not free.

You can use linkedIssues function and combine it with project name
Something like this:
issue in linkedIssues(XYZ-000) AND project = 'ABC'

I was able to get to the solution I needed with the following:
AND issueFunction in linkedIssuesOf("project in (ext_proj_1, ext_proj_2, ext_proj_3)") AND issueLinkType in ("depends on", "is blocked by")
I then used this in a dashboard where I showed the filter results and added the "Links" column so that users could see what projects we had external dependencies on.

Related

JQL Query to fetch linked bug for a JIRA feature

Say I have two project EPIC1 and BUG . I have linked all my concerned BUG with my EPIC1. Now, I am trying fetch all bug for EPIC1 fetaures.
I tried using below JQL to fetch all concerned BUG for this fetaures and I'm not sure how find the linked bug query in JQL.
JQL: project = "EPIC" AND key = EPIC-XXX and issuelink ... not sure how to get the QUERY
EPIC1-- linked
BUG1
BUG2
JIRA linking bUG
Linked Bug to fetaure EPIC1

how can I find all tickets that changed/moved projects?

The query I tried is Project CHANGED FROM "Customer triage", but jira says it's not supported.
Is there a way to query the tickets that were created in project A, but were moved?
Evidently, this is not possible to do out of box with JIRA; "Project" just doesn't support any historic search functionality:
https://confluence.atlassian.com/jiracoreserver073/advanced-searching-fields-reference-861257219.html#Advancedsearchingfieldsreference-ProjectProject
However, with some Googling, it appears you may be able to accomplish this with ScriptRunner:
https://community.atlassian.com/t5/Jira-questions/View-issues-that-have-been-moved-from-one-project-to-another/qaq-p/790346

How to get all boards in jira project using either Rest API or jira-ruby gem

I am trying to use this How to get all sprints in project using JIRA REST API to build code which gets all sprints for jira project. I miss one piece however: how to get all boards in jira project?
Proposed solution is to
use https://myjira.com/rest/agile/1.0/board to get all boards
and for every board to query https://myjira.com/rest/agile/1.0/board/BOARD_ID/project to find out if it belongs to my project.
However my jira has ~10'000 boards. I can't make 10'000 JIRA queries for them. I need something like https://myjira.com/rest/agile/1.0/board?project=PROJECTNAME. If that's not possible, then I need at least to include project name into /board result.
Acc. to https://docs.atlassian.com/jira-software/REST/7.3.1/?#agile/1.0/board-getAllBoards you can use the projectKeyOrId parameter in your GET request to provide the project's key, e.g.
https://myjira.com/rest/agile/1.0/board?projectKeyOrId=PROJECTNAME

JQL to find epics that are not linked to a theme

I can't find any examples of how to do this.
I want to filter all epics that are not linked to any issues of type "theme".
Is this possible?
I belive there's no JQL you can do without any add-on purchased.
If you can, try scriptrunner.
There you can do something like,
issuetype = Epic AND issueFunction not in hasLinkType("Epic-Story Link")
This gets results of all the epic issues with no issue linked expect Epic.
"issueFunction" is possible JQL only if you add ScriptRunner add-on.
Basically, in the Epic issue, "Issues In Epic", if there's no issues is in Epic, then it will be on the result.
For specific "theme" issue type, then you need to develop more with this script.
Not with JQL that I know of. I think that I would use Jira python to get the issue link information and filter out the unwanted epics
You can filter Epics with no theme with something like this: Type = Epic AND "Parent Link" is EMPTY AND resolution = Unresolved

JQL issues added to backlog

Is there a way in JQL to find issues that were added to backlog yesterday? I tried using Sprint changed to EMPTY and Backlog priority changed from empty but JIRA doesn't support historical search on those fields.
Thanks!
JQL indeed does not support history searches on the sprint field so you cannot search for issues that were removed from a sprint since yesterday.
You can however search for "new" issues that were added to the backlog since yesterday:
project = "MyProject" AND created > -1d AND sprint IS EMPTY
Or for issues on your backlog that were updated since yesterday:
project = "MyProject" AND updated > -1d AND sprint IS EMPTY
If that's not close enough to what you need, you could also use an add-on like Script Runner which comes with a number of JQL functions built-in, like removedAfterSprintStart. It also allows you to implement your own JQL functions. That way you could implement exactly the behavior that you desire.

Resources