周和月的 CAML 查询不起作用 [英] CAML Query for Week and Month not working

查看:43
本文介绍了周和月的 CAML 查询不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我遵循 CAML 查询不起作用:

I following CAML Query does not work:

<Where><DateRangesOverlap><FieldRef Name=\"EventDate\" /><FieldRef Name=\"RecurrenceID\" /><Value Type=\"DateTime\"><Week /></Value></DateRangesOverlap></Where>

AND

<Where><DateRangesOverlap><FieldRef Name=\"EventDate\" /><FieldRef Name=\"RecurrenceID\" /><Value Type=\"DateTime\"><Month/></Value></DateRangesOverlap></Where>

但这个有效:

<Where><DateRangesOverlap><FieldRef Name=\"EventDate\" /><FieldRef Name=\"RecurrenceID\" /><Value Type=\"DateTime\"><Yearly /></Value></DateRangesOverlap></Where>

唯一的区别是工作查询有 作为日期时间,非工作查询有 ><月/>.

The only difference is that the working query has <Yearly /> as Date time and the non working queries have <Week /> and <Month />.

这对我来说是个大问题,因为它对性能有很大的影响.有人可以就这里可能发生的事情提供一些指导吗?

This is a big issue for me as it has a big performance impact. Can someone provide some guidance as to what muight be happening here?

推荐答案

DateRangesOverlap 有很多问题,您面临的问题可以在这里解释:问题.同一作者提供了一个解决方案 解决方案

The DateRangesOverlap has many issues, the one you are facing might be explained here: Issue. The same author has provided a solution Solution

这篇关于周和月的 CAML 查询不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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