Forums

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

Automation - logging a list of issues - Same results, different order for each run

Christy Kennedy
Contributor
November 18, 2025

Hi all,

I am printing a list of issues into an automation audit log. Why aren't my results printing in alphabetical order by assignee name?

The automation does the below:

  1. Looks up issues based on a filter
  2. Ensures the list of issues in the filter is larger than 0
  3. Branch based on issues in the same filter
  4. Log a list of the issues (with issue key and assignee)

automation.jpg

 

 

The filter I reference is ordered by assignee first

my filter.jpg

 

 

Here are my audit log results where results are not printed in order by assignee

audit log.jpg

2 answers

4 votes
Anthony Morais
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.
November 18, 2025

Hi @Christy Kennedy 

 

The reason your audit log isn’t printing in alphabetical order is because filter = XYZ does not preserve the ORDER BY clause inside the Automation rule.
When Automation resolves the filter, the results come back unordered, even if the saved filter itself is sorted in the Issue Navigator.

To fix this, you just need to replace the filter reference with the full JQL, including your ORDER BY assignee ASC clause, directly inside the Lookup issues action.

I tested this out and it worked!

Screenshot2.png

 

Screenshot 1.png

 

Hope it helps!

4 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.
November 18, 2025

Hi @Christy Kennedy 

While the work items in your Lookup Work Items result are in the order the filter returned, a branch processes in parallel and asynchronously.  Thus, the logging order is undefined with a JQL branch.

You could remove the branch and write the information with a single log write using the lookup results to preserve the order:

The ordered list is:
{{#lookupIssues}}
* {{key}} -- {{assignee.displayName}};
{{/}}

Unfortunately, you cannot add line breaks to the log, so they will appear as a long string.

 

Kind regards,
Bill

Christy Kennedy
Contributor
November 18, 2025

Hi @Bill Sheboy - ah that makes sense. Will see what I can do here to fix it!

Like Bill Sheboy likes this

Suggest an answer

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

Atlassian Community Events