0

How could one get the last page of data using skip/take/inlinecount in a single odata query (Wcf Data Services)?

Fx.. With page size 25...

http://server:8000/Html5Controls/Services/SampleDBService.svc/Offices?$format=json&$top=25&$skip=0&$orderby=city

Would get the first page. Is there a way to combine the count to get the last page in a single query?

4

1 回答 1

0

不,目前没有办法做到这一点。(您需要一种方法来引用查询中的总计数,但这样的函数不存在)。您可以在两个查询中执行此操作:请求具有内联计数的第一页,获取该计数并计算最后一页的 $skip 值并请求该值。

于 2012-08-08T11:01:25.430 回答