月份之间查询
我想查询2007-4到2007-5份之间的数据。
数据库的格式是2007-4-4
数据库是ACCESS
------解决方案--------------------select * from tbl where d> =#2007-04-01# and d <#2007-05-01#
------解决方案--------------------starttime= "2007-4-1 "
endtime= "2007-5-31 "
sql= "select * from table where inputtime> = ' "&starttime& " ' and inputtime <= ' "&endtime& " ' "
------解决方案--------------------查询4月到5月底的记录
starttime= "2007-4-1 "
endtime= "2007-5-31 "
sql= "select * from table where inputtime> =# "&starttime& "# and inputtime <=# "&endtime& "# "