Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Search for epics with issues in another specific project

Florent06
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
September 14, 2022

All my epics are stored in a project A but all their stories are in other projects.

I want to get all epics that have issues in a specific project B :

issueFunction in issuesInEpics("project = B")

 

But this does not get any ticket. When I just search "project = B", I get a full list of tickets.

 

All the tickets I want to get are linked to epics in project A.

2 answers

1 vote
Trudy Claspill
Community Champion
September 14, 2022

Hello @Florent06 

Welcome to the community.

issuesInEpics returns the child issues of Epics, where the Epics match the filter you specify in the parentheses. Refer to 

https://scriptrunner.adaptavist.com/latest/jira/jql-functions.html?_ga=2.258035530.1301043823.1663180277-1406361688.1663002443#_issuesinepics

If you want to get the Epics you need to use epicsOf.

issuefunction in epicsOf("project=B")

...will give you all the Epics that have child issues in project B.

If you want to additionally limit the results to only the Epics that are in project A then add this:

issuetype=Epic and project=A and issuefunction in epicsOf("project=B")
Marc Isikoff
Contributor
January 10, 2024

Slightly different ask but still need epics from project B for a story in Project A.

1. We are trying to automate the Epic link in A as the manual step would be to go to the story in A, navigate to Epic Link, and start typing the account # there until you get a list of Epics from various projects that match (Epic names/summaries begin with account numbers) and pick the one from a specific project (or latest key from specific project if > 1). If there is none, create an Epic in B and then go back and start over.

We want to automate a way to do this but since we do not start with a linked Epic these functions do not work.

Trudy Claspill
Community Champion
January 10, 2024

@Marc Isikoff 

To get full community visibility on your question it is better to start a brand new Question than to post on an old (1+ year old) Question. If this post is relevant, include a link to it in your new Question.

When you add to an old question the only people who see your post are people who are watching the old question, have responded to the old question, and the original author.

0 votes
mauricio.groth
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.
September 15, 2022

Hi @Florent06 

As you're on Jira Server, the correct answer is to get an app that provides JQL extensions you're looking for.


With standard JQL, you can only get a list of issues and export them to Excel for further processing. This works if you want to do a one-off analysis. If your use case is more dynamic than that, look beyond standard Jira.

Standard JQL doesn't easily allow it, but you can quickly find the results using our professional indexing service JQL Search Extensions

You can use this query to find all your  epics that have issues from other projects

issue in epicOf("project = B”)

Check out the documentation for more examples.

If you have any other questions, please contact our support. We’ll be happy to help you!
Best regards,
Maurício

Suggest an answer

Log in or Sign up to answer