The value of the $orderby system query option contains a comma separated list of property navigation paths to sort by, where each property navigation path terminates on a primitive property.
A type cast, using the qualified entity type name, is required to order by a property defined on a derived type.
The property name may include the asc suffix for ascending or desc suffix for descending ordering, separated from the property name by one or more spaces.
$groupby=Fieldname asc/desc,Fieldname asc/desc
Example:
List of all items, order by Item Code ascending
odata4/Item?$select=ItemCode,ItemName&$orderby=ItemCode asc