Showing results for 
Search instead for 
Did you mean: 
Power Automate
Power Automate

Sort Ascending / Decending

What property drives which colum will be sorted when tapping the sort ascending/decending icon? Mine seems to be doing it's own thing. Smiley Frustrated





I tried also with your numbers, but it seems to work fine...

Could you please provide steps to reproduce the problem?






Thanks for sharing.

My scenario very very straightforward. Just no idea why!




Hi hpkeong,  I think it is because your "Number" field is actually text.


Does this work?


Sort( Table1, Value(Number))
Community Champion
Community Champion

Hi Meneghino

I guess so, too. In Excel, even it is set as Numeric, it did not work, too.
Anyway, I will try on CDS.
Thanks a lot for sharing of such a 😁 case.

Have a nice day.

I have display data from collection.


Dropdown list contain 3 values

Items = ["Name", "Maker","Price"]


- I have used Gallery to display data.

- When I select value from Dropdown list, Sorting work perfect. Let I selected Price from dropdown, then gallery display data sorted by Price. It works fine

- Now I want to apply Ascending / Decending on this sorted data when I click UpDown Icon. Please refer image for clarity of my question.

- How can I do this ?


Sort Que_Avnish New.png


Finally I got answer which is :


SortByColumns (PriceList,If(Dropdown.Selected.Value = "Name", "Name", Dropdown.Selected.Value = "Maker", "Maker", Dropdown.Selected.Value = "Price", "Price"), If(SortDescending1, Descending, Ascending))


When I use a people picker field like this "Employee" in the Search formula, it s giving me an error saying that "A field of text type is expected" and it is the same case with date type fields as well. Could you please let me know how can we use people picker and date fields in Search and SortByColumns formulas.

I looked and looked to try and figure out why my list was not sorted in numerical order. I used this simple post to get it to work! Thanks!


Dear Miss @aftowen 


I've tried to sort the records with serial number like 1,2,3,4... with the code your provided, but unfortunately it's not performing well, like its sorting in 1,10,11,12.. 2,20,21..,3,30,31... and so on.. 


Please help how to fix this.!

Helpful resources

New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

New Power Super Users


We are excited to announce the Power Apps Super Users!

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

Top Solution Authors
Top Kudoed Authors
Users online (47,345)