摘要: 一天"select * from T_news where datediff(day,addtime,getdate())=0";三天"select * from T_news where datediff(day,addtime,getdate())<= 2 and datediff(day,addtime,getdate())>= 0";一周"SELECT * FROM T_news WHERE (DATEPART(wk, addtime) = DATEPART(wk, GETDATE())) AND (DATEPART(yy, 阅读全文
posted @ 2013-06-09 16:24 城堡没公主 阅读(326) 评论(0) 推荐(0) 编辑