日期:2014-05-18 浏览次数:20493 次
select * from [Table] where dateadd(month,cast(b as int),a)>getdate()
------解决方案--------------------
select * from [Table] where a>dateadd(month,-cast(b as int),getdate()) --or select * from [Table] where datediff(ms,a,dateadd(month,-cast(b as int),getdate()))<0
------解决方案--------------------
select * from [Table] where dateadd(mm,cast(字段B as int),字段A )>getdate()