Forums

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

JQL custom field value to be the same in two different projects

Aaron Geister
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.
April 20, 2021

I need to use JQL to find a custom field value to be the same in two different project issues?

So project A issue drop down field value to = the value of project b issue drop down field value.

I thought i did this without script runner before. Need assistance.

2 answers

2 accepted

2 votes
Answer accepted
Joseph Chung Yin
Community Champion
April 20, 2021

@Aaron Geister -

Try this out...

project in (xyz, abc) and <dropdown_field> in (common-value 1, common-value 2)

Best, Joseph Chung Yin

Jira/JSM Functional Lead, Global Infrastructure Applications Team

Viasat Inc.

Aaron Geister
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.
April 20, 2021

But how can I compare that the value is = in both issues in the two different projects. I can query for the common value but I need to know they are the same on two different issues?

Aaron Geister
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.
April 20, 2021

Here is what I got so far:

project in ("projectA","projectB") AND "Clients[Dropdown]" in (common-value 1, common-value 2, common-value 3) AND project = projectA AND issuetype = "issuetype" AND status = Completed AND status changed BEFORE 14d

 

My issue is that I need to populate a value to show that one issue will equal another issue value to be the same from project A to project B.,

1 vote
Answer accepted
Nic Brough -Adaptavist-
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.
April 20, 2021

Jira's JQL does not have "field 1 = field 2" operators, they're all "field 1 has <value>" type clauses.

To find out if two issues have the same value, you have to read through the results of "field = X" to find out if both issues are on the list.

But you can easily copy field values from one issue to another - have a look at the automation functions and maybe the marketplace for "copy field" functions.

Aaron Geister
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.
April 20, 2021

No, I haven't looked yet. I thought I would have to use script runner but in the past I thought I was able to do this without an add-on like script runner. I use script runner in my instance but I am working with a client and trying to configure a Jira automation to capture data to link issues and notify.

I don't need to copy a field value, I just need to know if one fields value equal the same field value in two different issues in two different projects to link them together.

Dimitrios Moschovitis August 19, 2022

Did you have any luck with that?

Aaron Geister
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.
October 30, 2022

No I never had luck with this. 

Like Dimitrios Moschovitis likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events