各位前辈:我要做一个班报表,要求查询,0点7点 20点23点的数据。两个时间段的查询我知道,但四个时间段的查询我就不知道了,请问语句怎么修改呢
Sql = "select * from baobiao where riqi between '" & BeginDate & "' and'" & EndDate & "' order by 1",谢谢
------解决方案--------------------
Sql = "select * from baobiao where (riqi between '" & BeginDate & "' and'" & EndDate & "') OR (riqi between '" & BeginDate1 & "' and'" & EndDate2 & "') order by 1",