Forums

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

Automation not working as expected with multi-select custom field

Durell Demartini
Contributor
January 5, 2023

Hello all,

We're using Jira Automation to create sub-tasks. We have a custom field of type multi-select called, "Type of Modify" with options "Storage" and "Compute." Within the automation rule, we want to build logic that IF "Storage" is selected then generate a sub-task for Storage, or IF "Compute" is selected then generate a sub-task for Compute. IF both options are selected, then generate sub-tasks for both Storage and Compute.

Here are the conditions for the custom field:

  • contains any of
  • contains all of
  • contains none of
  • equals (in any order)
  • is empty
  • is not empty

I've used the condition, "contains any of," and it is working successfully when both Storage and Compute are selected - both sub-tasks are getting created successfully.

However, when only one or the other option is selected, only the first IF logic is being checked, (in this case Storage) and is successful in creating the Storage sub-task. If I select Compute, then the status in the audit log is "no actions performed."

What am I doing wrong? Any ideas? Thanks in advance for reviewing my question.

2023-01-05_15-18-01.png

 

1 answer

1 accepted

5 votes
Answer accepted
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.
January 5, 2023

Hi @Durell Demartini 

Your rule is stopping processing because of the way the if-conditions are noted.  When you want processing to continue, please try using if/else conditions or branches.  Such as:

  • trigger: your selected trigger
  • if/else
    • condition: if contains the Storage value
      • action: create the sub-task desired
  • with a new if/else
    • condition: if contains the Compute value
      • action: create the sub-task desired

Or try with branches

  • trigger: your selected trigger
  • branch on current issue
    • condition: if contains the Storage value
      • action: create the sub-task desired
  • branch on current issue
    • condition: if contains the Compute value
      • action: create the sub-task desired

Kind regards,
Bill

Dawid Joshua _TechTime_
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.
January 5, 2023

What @Bill Sheboy says. Let me just add a note or two. 

  • Both conditions should be "contains any of". 
  • Instead of the action "Create issue", you could use "Create sub-task". 
  • As Sub-tasks can't be created for Epic-level issues, add a condition to exclude Epics. This will prevent errors. you don't need this if you already filter them out in your trigger step.
    Screen Shot 2023-01-06 at 1.30.41 PM.png

Cheers,
Dawid

Like Aaron Brady likes this
Durell Demartini
Contributor
January 5, 2023

Thanks very much for the quick replies and helpful information. @Bill Sheboy I failed to include that I had already tried if/else with no success. However, I hadn't tried the branching, so I did try that option, and it worked. Thanks again!

Like Bill Sheboy likes this

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, atlassian government cloud, fedramp, webinar, register for webinar, atlassian cloud webinar, fedramp moderate offering, work faster with cloud

Unlocking the future with Atlassian Government Cloud ☁️

Atlassian Government Cloud has achieved FedRAMP Authorization at the Moderate level! Join our webinar to learn how you can accelerate mission success and move work forward faster in cloud, all while ensuring your critical data is secure.

Register Now
AUG Leaders

Atlassian Community Events