这个sql该怎样写

来源:百度知道 编辑:UC知道 时间:2024/06/20 08:46:16
有一Access表tips
id content date
1 test 2009-2-15
2 测试 2009-2-4
想在(date)之前都显示content的内容,过后不显示,ASP+SQL该怎样写
select content from tips where date>=getdate()
会提示没有定义getdate()

select * from 表 where 日期字段between '2005/12/12 and 2005/12/30

select * from 表 where convert(int,日期字段)> 20051212 and convert(int,日期字段) <20051230
===============================
SQL="SELECT * FROM 航线信息 where datediff('d',?????,GetDate())=0"

SQL="SELECT * FROM 航线信息"
.......................
if datediff("d",rs("日期字段"),date())=0 then
只能用判断
=================================

select content from tips where date>=getdate()

getdate() 是SQL SERVER的内置函数,access中应该用date()

select content from tips where [date]>=date()