首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > Ajax >

请问一个SQL命令

2013-11-23 
请教一个SQL命令请教一个SQL命令一个SQL表,有一个字段deal_date 现要求取出:从getdate()前二个月,到getdat

请教一个SQL命令
请教一个SQL命令

一个SQL表,有一个字段deal_date 

现要求取出:从getdate()前二个月,到getdate()之间的记录.


select * from 表 where getdate()....
[解决办法]
select * from 表 where deal_date between getdate() and DATEADD ( m , -2 , getdate() ) 

热点排行