0
可以告訴我如何使用CAML查詢將SPList中存儲的日期和時間與日期時間字段與當前系統時間進行比較?SPList中的查詢日期時間字段
可以告訴我如何使用CAML查詢將SPList中存儲的日期和時間與日期時間字段與當前系統時間進行比較?SPList中的查詢日期時間字段
要以今天的日期比較:
<Where>
<Lt>
<FieldRef Name='Created'/>
<Value type='DateTime'><Today /></Value>
</Lt>
</Where>
比較今天的日期和時間
<Where>
<Lt>
<FieldRef Name='Created'/>
<Value type='DateTime' IncludeDateTime='TRUE'><Today /></Value>
</Lt>
</Where>
比較方昨日
<Where>
<Lt>
<FieldRef Name='Created'/>
<Value type='DateTime'><Today Offset='-1' /></Value>
</Lt>
</Where>
比較昨天的日期應該是 「OffsetDays」
<Where>
<Lt>
<FieldRef Name='Created'/>
<Value type='DateTime'><Today OffsetDays='-1' /></Value>
</Lt>
</Where>