Copy custom field value from project A to linked epic in project B

Daniel Wilde September 6, 2024

hi community,

my dilemma is an automation rule which I couldn't get running.

We want to copy a value from a custom field (10134) of issuetype X in project A to its linked issues of issuetype epic in project B. The issues are linked with type "relates". Both issuetypes are using the custom field (10134). The rule shall perform once a day.

 

  • Trigger: scheduled (on a daily base)
  • condition 1: project A with issues of type X which have values in custom field (10134) and which are linked via "relates to" to issues of type epic in project B
  • action: copy value from custom field (10134) from issues of type X in project A to the same custom field (10134) of its specific linked issues of type epic in project B

 

I'm struggling with the configuration.

1 answer

1 accepted

0 votes
Answer accepted
Marc - Devoteam
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 6, 2024

Hi @Daniel Wilde 

You need to use a branch in your rule based on linked issues of the type relates to.

Branch after your condition.

Example:

Screenshot 2024-09-06 at 14.03.02.png

Daniel Wilde September 6, 2024

hi @Marc - Devoteam,

thanks for quick answer. Similiar configurations I've tried already but as you can see in the second screenshot, the audit log tells me that there is no issue found.

 

image.png

 

image.png

Marc - Devoteam
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 6, 2024

Hi @Daniel Wilde 

What is the config of the scheduled trigger, is there a JQL clause stated?

If so remove it, as the JQL is in your clause.

Daniel Wilde September 9, 2024

Hi @Marc - Devoteam 

Your last answer brought me on the right way.


I used "issuetype = epic" for the trigger but as you wrote correctly it was redundant. Instead I changed the trigger's jql request to "project = PN AND issuetype = Projekt AND "ZEP-Projekt (Link)" != Empty". "type = epic" is now used just once in branch's condition (key = ... was only for a test run).

 

Hopefully, it does now what i expect.

 

One additional question: Soon, I'd like to add more issue fields but I only wanna copy values from issues where the fields aren't empty. How can I request that for several fields where at least one of it is not empty? And would the rule also copy empty fields to a maybe non-empty field? That would be counterproductive.

 

image.png

Marc - Devoteam
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 9, 2024

Hi @Daniel Wilde 

Then you would need IF/ELSE clause and then branch in the clause.

Yes if you copy fields on the eit and the field is empty, the existing value will be overwritten.

Suggest an answer

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

Atlassian Community Events