Forums

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

Looping through lookup objects results

Ste404
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 3, 2024

Hi there,

I am stuck trying to loop through results from a lookup objects in Assets.

For each of my returned records there is an email address.

I want to loop through the results and per object send an email to that address.

When there are no more results, no more emails.

I have the lookup working, I can see 20 objects with 20 email addresses, but I try an AQL branch and only get one email sent.

What do I need to do to loop through the send email node in the automation to cover all 20 records.

 

2 answers

0 votes
Melissa Nielsen May 2, 2025

You must use the 'Branch on AQL' branching. It only appears in the 'Advanced Branching' options if your rule has a GLOBAL scope. 

aql.png

0 votes
Joseph Chung Yin
Community Champion
March 3, 2024

@Ste404 -

Although I am not extermely familiar on the AQL branch, based on this article's AQL section - https://support.atlassian.com/cloud-automation/docs/jira-automation-branches/

It did stated that "When configuring actions, you can access the details of each object using the {{object}} smart value" and there is a limitation of 50 objects max.

You may need to "Send email" action within the the branch.

Hope this helps.

Best, Joseph Chung Yin

Jira/JSM Functional Lead, Global Technology Applications Team

Viasat Inc.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events