GetListItems未返回SharePoint 2013中的项目

GetListItems未返回SharePoint 2013中的项目,sharepoint,sharepoint-2010,sharepoint-2013,caml,Sharepoint,Sharepoint 2010,Sharepoint 2013,Caml,我们正在查询SharePoint 2013 webservice方法-GetListItems以获取列表中的项目列表,但它返回0个项目。奇怪的是,SharePoint 2010使用的代码与用于返回指定SharePoint列表中的文件列表的代码相同,但自升级到SharePoint 2013以来,它返回0个项目,甚至没有引发任何异常 以下是传递给GetListItems方法的参数 <GetListItems xmlns="http://schemas.microsoft.com/sharepo

我们正在查询SharePoint 2013 webservice方法-GetListItems以获取列表中的项目列表,但它返回0个项目。奇怪的是,SharePoint 2010使用的代码与用于返回指定SharePoint列表中的文件列表的代码相同,但自升级到SharePoint 2013以来,它返回0个项目,甚至没有引发任何异常

以下是传递给GetListItems方法的参数

<GetListItems xmlns="http://schemas.microsoft.com/sharepoint/soap/">
<listName>Accounts</listName>
<query>
<Query xmlns="">
<Where><Contains><FieldRef Name="FileDirRef" /><Value Type="Text">foldertoread</Value></Contains></Where>
</Query></query>
<viewFields><ViewFields xmlns="" /></viewFields>
<rowLimit>50</rowLimit>
<queryOptions>
<QueryOptions xmlns=""><Folder>foldertoread</Folder></QueryOptions>
</queryOptions>
</GetListItems>

账户
翻页机
50
翻页机

看起来SharePoint2013对标签的感知方式发生了微妙的变化。我们没有提到文件夹名称,而是必须提到完整的文件夹路径,它才能工作

修改后的参数列表有效:

<GetListItems xmlns="http://schemas.microsoft.com/sharepoint/soap/">
<listName>Accounts</listName>
<query>
<Query xmlns="">
<Where><Contains><FieldRef Name="FileDirRef" /><Value Type="Text">foldertoread</Value></Contains></Where>
</Query></query>
<viewFields><ViewFields xmlns="" /></viewFields>
<rowLimit>50</rowLimit>
<queryOptions>
<QueryOptions xmlns=""><Folder>Accounts/foldertoread</Folder></QueryOptions>
</queryOptions>
</GetListItems>

账户
翻页机
50
帐户/文件夹阅读