select count(*) from 表名 where addtime>"指定时间" and addtime<"指定时间"
Select count(*) from 表 where addtime between "时间" and "时间"
declare @时间1 smalldatetimedeclare @时间2 smalldatetime set @时间1="2008-01-01"set @时间1="2008-01-02"Select count(*) from 表 where addtime between @时间1 and @时间2
declare @时间1 smalldatetimedeclare @时间2 smalldatetime
set @时间1="2008-01-01"set @时间1="2008-01-02"Select count(*) from 表 where addtime between @时间1 and @时间2
另问,access中要把字符型转换成整型用什么函数