How to copy custom field [Select List (multiple choices)] from linked issue

Martin Kovalcik
Contributor
March 10, 2025

 

Hi, I can't figure out how to copy [Select List (multiple choices)] custom field from linked issue.

Other fields work fine.

 

image.png

 

I need to copy one more custom field - customfield_10177.

The type of this field is Select List (multiple choices).

Smart value {{issue.issuelinks.inwardIssue.customfield_10177}} doesn't work.

 

I want the rule to be manually triggered from the edited issue.

 

  • both projects are company-managed
  • image of my rule

    image.png

 

  • image of my Edit issue action

    image.png
  • image from audit log

    image.png

1 answer

0 votes
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.
March 10, 2025

Hi @Martin Kovalcik 

For a question like this, context is important for the community to help.  Please post the following:

  • what type of project is this (e.g., company-managed, team-managed, etc.), 
  • an image of your complete automation rule in a single image for continuity,
  • images of any relevant actions / conditions / branches,
  • an image of the audit log details showing the rule execution, and
  • explain what is not working as expected and why you believe that to be the case.

Until we see those...

Have you confirmed that each of those field edits actually works as you expect?  The concern is two-fold:

  • While the {{issue.issuelinks}} field contains some of the fields for the linked issues, it does not contain them all.  Generally, one needs to use the Lookup Issues action with JQL, or a branch, to fully load the issue data before use in other rule steps / actions.
  • When accessing something like {{issue.issuelinks.inwardIssue.customfield_12345}} that could be a list of values when there are multiple linked issues.  As a result, there could be unexpected results.  This is another reason to specifically select the issue needed, with with smart value, list filtering or the Lookup Issues action.

 

Next, for multiple-select option field, you may need to use JSON to add the values: https://support.atlassian.com/cloud-automation/docs/advanced-field-editing-using-json/#Multi-select-custom-field

If we assume the data for customfield_10177 is actually loaded with the issuelinks smart value, and there is one-and-only-one issue in the inwardIssue attribute, this might work with the function asJsonObjectArray():

{
"fields": {
"customfield_10177": {{issue.issuelinks.inwardIssue.customfield_10177.asJsonObjectArray("value")}}
}
}

 

Kind regards,
Bill

Martin Kovalcik
Contributor
March 10, 2025

there is only one linked issue and the copied custom fields exist in both issues

the type of source and destination customfield_10177 is [Select List (multiple choices)] and the valid options for this field are also the same

other copied custom fields work exactly as I wanted

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.
March 10, 2025

I was not noting the fields exist (or not) in the issue types used.  But instead that the {{issue.issuelinks}} smart value does not load all of the associated data by default for a specific issue.  If it did, one could imagine a situation were a single issue with linked ones could pull thousands of others, in an ever increasing tree of links, including duplicates of the same issue.  Regardless of that...

 

Did you try the JSON expression I suggested rather than setting the field from the dropdown list?

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events