查询条件为某日期变量在某段日期常量之间该怎么表达?

看看下面查询有什么错误:
"select * frome s_book where [出版时间] between #"_
& DateAdd("m", -6, DateValue(Text4.Text))_
& "# and #"_
& DateAdd("m", 6, DateValue(Text4.Text)) & "#"
收到异常:类型不匹配

---------------------------------------------------------------

"select * frome s_book where [出版时间] between '"_
& DateAdd("m", -6, DateValue(Text4.Text))_
& "' and '"_
& DateAdd("m", 6, DateValue(Text4.Text)) & "'"

Published At
Categories with 数据库类
Tagged with
comments powered by Disqus