web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / ODATA query for MySQL ...
Power Automate
Unanswered

ODATA query for MySQL action to arrange data in a specific order based on predefined values.

(0) ShareShare
ReportReport
Posted on by 6

After extracting the data filtered by creation type, my intention is to arrange the data based on the the approval_type column in the folllowing order : "Initiator" first, followed by "Reviewer" and finally "Approver". I am not sure what went wrong in my ODATA order by query and hope to seek your assistance.

 

ODATA Order By query:

?$orderby=approval_type desc&$orderby=approval_type eq 'Initiator' desc&$orderby=approval_type eq 'Reviewer' desc&$orderby=approval_type eq 'Approver' desc

 

 

This is the error detail that I received:
Expression expected at position 0 in '?$orderby=approval_type desc&$orderby=approval_type eq 'Initiator' desc&$orderby=approval_type eq 'Reviewer' desc&$orderby=approval_type eq 'Approver' desc'.
inner exception: Expression expected at position 0 in '?$orderby=approval_type desc&$orderby=approval_type eq 'Initiator' desc&$orderby=approval_type eq 'Reviewer' desc&$orderby=approval_type eq 'Approver' desc'.
clientRequestId: 6ec5ede0-ecde-4c33-a0dd-9c5f07062dc3

 

 

error.PNG
pa.PNG
Categories:
I have the same question (0)
  • lbendlin Profile Picture
    8,649 Super User 2026 Season 1 on at
    $orderby=approval_type eq 'Initiator' desc

    you are mixing filters and sort instructions.  Do either or.

     

    Can't you do all the sorting and filtering in your MySQL native query?

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 594

#2
Valantis Profile Picture

Valantis 328

#3
David_MA Profile Picture

David_MA 281 Super User 2026 Season 1

Last 30 days Overall leaderboard