sql server比較時間大小DATEDIFF

DATEDIFF(day,#{rebaTimeStart},a.CreateTime)>=0 AND DATEDIFF(day,a.CreateTime,#{rebaTimeEnd} )>=0im

day:以天比較tar

DATEDIFF(day,#{TimeStart},a.CreateTime)=1:

以天比較,

等於1:爲CreateTime大於TimeStart

等於0:CreateTime等於TimeStart

等於-1:CreateTime小於TimeStart

相關文章
相關標籤/搜索