【发布时间】:2012-09-24 19:32:16
【问题描述】:
我正在尝试使用此 URL 在 OData 中进行一些自定义排序
localhost:82/odata.svc/ComponentPresentations?$filter=TemplateId eq 2894 and publicationId eq 10&$expand=Component/Keywords?$orderby=Title desc
其中Component是ComponentPresentation的属性,Keywords是Component的属性,我想根据关键字的Title属性对ComponentPresentation进行排序。但是关键字和标题是组件表示的属性
有没有办法根据 Keword 的 title 属性对结果进行排序?哪个是Component的子代,哪个是ComponentPresentation的子代?
【问题讨论】:
-
@VladL 以上...(对不起,我没有代表点评论),我认为这也行不通。我刚刚尝试了一下,并将 Quantity 添加到 Order_Details 的 select 语句中:services.odata.org/V4/Northwind/Northwind.svc/… 看来 Order_Details 没有按 Quantity 排序。
标签: odata