怎样为delphi自带的桌面数据库日期型字段赋值? select count(clientid) as aVariant from table1 where comdate='2003-05-16'我用上面的查询语句时报错:Type mismatch in expression.高手指教后面的'2003-05-16'应该怎么写才对? 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 用参数where comdate=:comdate然后ParamByName('comdate') := EncodeDate(2003,5,16);然后再返回数据集 我的具体代码如下:tryquery1.Close;strday:=formatdatetime('yyyy-mm-dd',now);strSql:='select count (clientid) as acount from clientreginfo where comdate='+quotedstr(strday);query1.SQL.text:=strSql;query1.Prepare;query1.Open;except....end;其中comdate字段定义为date型,运行时报错如题,各位大侠给看看,应该怎么改? 用参数传不报错了,但返回值却总是0而且不能察看query1.sql.text的完整的值郁闷! KSEdit的注册问题 cxListBox 选中项的问题! 关于批更新 传送和接收txt 请frend进来拿分! 如何使窗口在运行时没有最大、最小按钮啊 怎么样才能知道一个文件的大小?(在线等待) 怎么样判断edit1.text全是数字,而没有字母或其它符号??急 用!!! 知其下落者,请明示:哪有API函数可以下载?我想学习API编程. 如何编写类似Treeview结构的目录选取对话框,或者有这方面的VCL吗?份是不多,望大哥赐教 关于窗口状态检测的问题 &=&=&=>> [600]分求IT产品(软件)好名字 <<=&=&=&
where comdate=:comdate
然后
ParamByName('comdate') := EncodeDate(2003,5,16);
然后再返回数据集
try
query1.Close;
strday:=formatdatetime('yyyy-mm-dd',now);
strSql:='select count (clientid) as acount from clientreginfo where comdate='+quotedstr(strday);
query1.SQL.text:=strSql;
query1.Prepare;
query1.Open;
except
....
end;
其中comdate字段定义为date型,
运行时报错如题,各位大侠给看看,应该怎么改?
而且不能察看query1.sql.text的完整的值
郁闷!