<Query>
<OrderBy>
<FieldRef Name="EventDate"/>
</OrderBy>
<Where>
<And>
<DateRangesOverlap>
<FieldRef Name="EventDate"/>
<FieldRef Name="EndDate"/>
<FieldRef Name="RecurrenceID"/>
<Value Type="DateTime" IncludeTimeValue="False">
<Today/>
</Value>
</DateRangesOverlap>
<Lt>
<FieldRef Name="EventDate"/>
<Value Type="DateTime">
<Today/>
</Value>
</Lt>
</And>
</Where>
<QueryOptions>
<IncludeMandatoryColumns>false</IncludeMandatoryColumns>
<ViewAttributes Scope="Recursive"/>
<RecurrencePatternXMLVersion>v3</RecurrencePatternXMLVersion>
<ExpandRecurrence>true</ExpandRecurrence>
<RecurrenceOrderBy>true</RecurrenceOrderBy>
<ViewAttributes Scope="RecursiveAll"/>
<CalendarDate>
<Today/>
</CalendarDate>
</QueryOptions>
</Query>
<OrderBy>
<FieldRef Name="EventDate"/>
</OrderBy>
<Where>
<And>
<DateRangesOverlap>
<FieldRef Name="EventDate"/>
<FieldRef Name="EndDate"/>
<FieldRef Name="RecurrenceID"/>
<Value Type="DateTime" IncludeTimeValue="False">
<Today/>
</Value>
</DateRangesOverlap>
<Lt>
<FieldRef Name="EventDate"/>
<Value Type="DateTime">
<Today/>
</Value>
</Lt>
</And>
</Where>
<QueryOptions>
<IncludeMandatoryColumns>false</IncludeMandatoryColumns>
<ViewAttributes Scope="Recursive"/>
<RecurrencePatternXMLVersion>v3</RecurrencePatternXMLVersion>
<ExpandRecurrence>true</ExpandRecurrence>
<RecurrenceOrderBy>true</RecurrenceOrderBy>
<ViewAttributes Scope="RecursiveAll"/>
<CalendarDate>
<Today/>
</CalendarDate>
</QueryOptions>
</Query>
Hello, What if I wanted to get recurring events for a date range?
ReplyDelete