按lastModifiedDatetime筛选Onedrive项目 [英] Filtering Onedrive items by lastModifiedDatetime

查看:105
本文介绍了按lastModifiedDatetime筛选Onedrive项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试通过lastModifiedDatetime属性从Microsoft Graph端点中筛选OneDrive项目.

I try to filter OneDrive items from within the Microsoft Graph endpoint, by lastModifiedDatetime property.

类似的东西:

https://graph.microsoft.com/beta/me/drive/special/photos/children?$top=3&$orderBy=lastModifiedDatetime

它不起作用. 返回的错误是:

It doesn't work. The error returned is :

消息":系统不支持该请求."

"message": "The request is not supported by the system."

但是根据文档( https: //dev.onedrive.com/odata/optional-query-parameters.htm#optional-odata-query-parameters )

oderby :逗号分隔的属性列表,用于对响应集合中项目的顺序进行排序.适用于名称,大小和lastModifiedDateTime字段.

oderby : Comma-separated list of properties that are used to sort the order of items in the response collection. Works for name, size, and lastModifiedDateTime fields.

顺便说一句,我尝试使用name属性进行排序,它实际上按预期方式工作:

By the way, I tried to sort with the name property and it actually works as expected :

https://graph.microsoft.com/beta/me/drive/special/photos/children?$top=3&$orderBy=lastModifiedDatetime

您是否可以确认图api端点不允许按 lastModifiedDateTime 进行排序?

Can you confirm than sorting by lastModifiedDateTime is not permitted with the graph api endpoint ?

推荐答案

按lastModifiedDateTime进行过滤. OneDrive Personal支持它.该限制并不特定于Microsoft Graph端点.在参考的文档页面中有关于此的注释.

Filtering by lastModifiedDateTime is not supported for OneDrive for Business. It is supported for OneDrive Personal. The limitation is not specific to the Microsoft Graph endpoint. There is a note about it in the referenced documentation page.

这篇关于按lastModifiedDatetime筛选Onedrive项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆