Sorting an Action List in Power Automate
I am trying to sort the output of an Action List by the Action Solicitor/Fundraiser. The Sort functionality seems simple, but isn't working for me. Any thoughts? It is likely either syntax or placement.
First, I tried to sort the “Append to Array” results near the end of the flow. I don't get an error, but it doesn't sort.

Then I tried sorting right after the list, but get an error.


Comments
-
@Reuben Schmitz It appears that I neglected to use the Compose Output - is working as it should.
0 -
@Reuben Schmitz
To use the sort() expression, you can read it here:when you sort without providing the “sortBy” I think it sort based on the first “simple” property it can find, which may not be the sorting you want.
First point is, you have to use the action that you did the sort on (Compose action), or you can using the array sorted directly in a apply to each loop or create html action. But if you use dynamic content directly from the Action List for Audit variable or List actions action, then the order is still going to the be “old” order before sort.
Also, you “can't” really sort on the List actions array of actions, as fundraiser is an array of system record id of the fundraiser, unlikely what you want to sort by, nor can sort by as array is not a simple type.
Then the question becomes, how are you handling action that has multiple fundraiser? From your Append to array variable action, it seems you are using a dynamic content called “Name”, but without seeing what your Apply to each looks like, can't really tell if you are using another apply to each for fundraiser array or only getting “first()” fundraiser.
Anyway, you don't need a separate Compose action (you can if you want), instead you can do the sort in the create html table action as the array from which you are creating html table for:
sort(variables('Action List for Audit'), ‘Action Solicitor Name’)
0
Categories
- All Categories
- 6 Blackbaud Community Help
- 211 bbcon®
- 1.4K Blackbaud Altru®
- 402 Blackbaud Award Management™ and Blackbaud Stewardship Management™
- 1.1K Blackbaud CRM™ and Blackbaud Internet Solutions™
- 15 donorCentrics®
- 360 Blackbaud eTapestry®
- 2.6K Blackbaud Financial Edge NXT®
- 657 Blackbaud Grantmaking™
- 577 Blackbaud Education Management Solutions for Higher Education
- 3.2K Blackbaud Education Management Solutions for K-12 Schools
- 941 Blackbaud Luminate Online® and Blackbaud TeamRaiser®
- 84 JustGiving® from Blackbaud®
- 6.7K Blackbaud Raiser's Edge NXT®
- 3.7K SKY Developer
- 248 ResearchPoint™
- 120 Blackbaud Tuition Management™
- 165 Organizational Best Practices
- 240 Member Lounge (Just for Fun)
- 34 Blackbaud Community Challenges
- 37 PowerUp Challenges
- 3 (Open) PowerUp Challenge: Grid View Batch
- 3 (Closed) PowerUp Challenge: Chat for Blackbaud AI
- 3 (Closed) PowerUp Challenge: Data Health
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Product Update Briefing
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Standard Reports+
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Email Marketing
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Gift Management
- 4 (Closed) Raiser's Edge NXT PowerUp Challenge: Event Management
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Home Page
- 4 (Closed) Raiser's Edge NXT PowerUp Challenge: Standard Reports
- 4 (Closed) Raiser's Edge NXT PowerUp Challenge: Query
- 796 Community News
- 3K Jobs Board
- 54 Blackbaud SKY® Reporting Announcements
- 47 Blackbaud CRM Higher Ed Product Advisory Group (HE PAG)
- 19 Blackbaud CRM Product Advisory Group (BBCRM PAG)

