Forums

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

Auto link issues with same field value

Prathap DL
Contributor
July 23, 2024

Hi Community.

 

i have Single line text custom Field(For Serial number) in "Project A" "issue type A" When ticket is creating user will enter Value to custom Field and creates ticket.

In "Project B" "issue type B" i have one multi line text custom Field Where user will enter Single or Multiple Serial number which is already created in "Project A" 

Here My question is Whenever Serial number is entered in Project B issue type B ticket, Automatically it should link with Project A issue type A ticket. If User enter 3 Serial number in project B then All 3 tickets from Project A should auto link with Project B ticket.

 

 

2 answers

1 vote
Bibek Behera
Community Champion
July 23, 2024

@Prathap DL ,

Looks doable, If my assumptions are correct. However, you might end up having too many links.

Things to do:

Try creating a filter on Project A with the field value you want to filter.

Use the same filter in automation for the list on issues.

Monitor for the field value change, and set the Link using the outcome of the JQL match.

-Bibek

 

Prathap DL
Contributor
July 23, 2024

Hi @Bibek Behera 

Thanks for the Reply. I'm new to this Jira and Automation Rule. So could you please provide the More Details or Automation Rule which can i use as reference.

Thanks

0 votes
Oday Rafeh
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.
July 23, 2024

Hi @Prathap DL , 

Welcome to the Community 

 

You can do that with Automation Rules, 

  • Go to Project Settings > Automation, create a new rule with the trigger Issue Created, add a condition to check if the issue is of type B in Project B, and use a branch rule to iterate over the serial numbers entered.

 

Prathap DL
Contributor
July 23, 2024

Hi @Oday Rafeh 

Thanks for the Reply. I'm new to this Jira and Automation Rule. So could you please provide the More Details or Automation Rule which can i use as reference.

 

Thanks,

Like Oday Rafeh likes this
Oday Rafeh
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.
July 23, 2024

Hi @Prathap DL , 

I will try to make it simple : 

To automatically link issues based on serial numbers, follow these steps in Jira:

  1. Go to Project Settings> Automation.
  2. Create a new rule with the trigger Issue Created.
  3. Add a condition to check if the issue is of type B in Project B.
  4. Use a branch rule to iterate over the serial numbers entered.
  5. Add a JQL condition to find matching issues in Project A:
    project = "Project A" AND issuetype = "issue type A" AND "Serial Number" ~ "{{field}}"
    
  6. Link the found issues to the current issue. 

I hope this will help you if this doesn't help let me know and I will create screenshots for you on how to do it. 

Bill Sheboy
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.
July 23, 2024

Greetings,

Project-scope rules may create or clone issues in other projects, but cannot access them otherwise.

Rules which access (or update) issues in multiple projects must have global or multiple-project scope.  Such rules are defined in the global automation area, not in the project settings.  Your Jira site admin will need to configure such a rule.

Kind regards,
Bill

Prathap DL
Contributor
July 23, 2024

@Oday Rafeh 

I tried above steps which you given but I'm not able to use {{field}} in JQL. instead i tried Serial number field is not Empty.

Now all the tickets in project A which has serial numbers all linking to Project B single ticket.

I used below rule 

I want Project B custom field value to match with Project A custom field value. then only it should link with each other.

Note: Project B custom field name and project A custom Field name is different.

And Project B field can have multiple Serial numbers in it. in that case all the tickets related project A should link with Single ticket in Project B

image.png

Oday Rafeh
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.
July 24, 2024

@Prathap DL Hi again 

try to write you JQL like this : 

project = "Project A" AND issuetype = "Issue Type A" AND "Serial Number" ~ "{{customfield_xxxxx}}"

 this JQl should find issues in Project A that match the serial numbers entered in Project B.

Prathap DL
Contributor
July 24, 2024

Hi @Oday Rafeh 

I tried above JQL and getting Error. Please find the Rule screenshot and Audit Log

 

image.pngimage.png

Oday Rafeh
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.
July 24, 2024

For you JQL this what you need to adjust to work with custom field smart value : 

{{issue.customfield_xxxxx}} 

 

Prathap DL
Contributor
July 24, 2024

Hi @Oday Rafeh 

I tried this also but same error.

Suggest an answer

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

Atlassian Community Events