日期:2014-05-18 浏览次数:20577 次
select * from VisitLog where VisitDate between @Date and dateadd(year,@Date,1)
------解决方案--------------------
create PROCEDURE GetVisitorsByYear @Date varchar(50) AS BEGIN SET NOCOUNT ON; select * from VisitLog where VisitDate between @Date and dateadd(year,1,@Date) SET NOCOUNT Off; END
------解决方案--------------------
exec GetVisitorsByYear '2008-01-01'