SQL.Add('Select * From 表名 Where (myDate between :stratdate and :enddate)');
ParamByName('stratdate').asdate:= StrToDate('2003-11-11');
ParamByName('enddate').asdate:= StrToDate('2003-11-12');
select * from 表名 where mydate between '''+formatdatetime('yyyy-mm-dd',timebegin)+''' and '''+formatdatetime('yyyy-mm-dd',timeend)+''''
时间类型就是浮点类型,其中1表示为1天,小数部分类推。