F
fossil
Unregistered / Unconfirmed
GUEST, unregistred user!
数据库为SQL SERVER
select PersonAttend.YYYYDD, PersonAttend.PNo, PersonAttend.Onwork, PersonAttend.Freework, Persons.PNo,
Persons.Pname, Persons.DNo
from PersonAttend, Persons where (Persons.PNo=PersonAttend.PNo)
and (Persons.DNo='DN') and (PersonAttend.YYYYDD between '2002-09-01' and '2002-10-31')
以上语句能正常返回数据,如果加上
and (PersonAttend.OnWork between '08:35:00' and '09:15:00')
其中OnWork 是时间字段类型,这样什么数据也返回不了,这是什么原因!肯定有数据满足这样的条件
select PersonAttend.YYYYDD, PersonAttend.PNo, PersonAttend.Onwork, PersonAttend.Freework, Persons.PNo,
Persons.Pname, Persons.DNo
from PersonAttend, Persons where (Persons.PNo=PersonAttend.PNo)
and (Persons.DNo='DN') and (PersonAttend.YYYYDD between '2002-09-01' and '2002-10-31')
以上语句能正常返回数据,如果加上
and (PersonAttend.OnWork between '08:35:00' and '09:15:00')
其中OnWork 是时间字段类型,这样什么数据也返回不了,这是什么原因!肯定有数据满足这样的条件