用 adoquery 控件,,一次删除表中的所有纪录,,,,
ADOQUERY.DELECTRECORDS(ARALL) ; 怎么不可以呢??
需要怎么写,请老师们给写出。谢谢!!
ADOQUERY.DELECTRECORDS(ARALL) ; 怎么不可以呢??
需要怎么写,请老师们给写出。谢谢!!
解决方案 »
- toolbar最右边放个combobox,程序运行时却走到早间?
- delphi开发的soap服务,客户端调用出错
- 如何取出cxLookupComboBox多列的值.
- 如何捕获ClientDataSet.ApplyUpdates的错误,不用ReconcileError
- 我用application.MessageBox('提示内容',‘提示’,MB_OK);时默认的“确定”按钮是中文,怎样才能使它变成英文啊?
- 问问大家,原创文章被别人使用,但没有注明转帖是什么感觉?
- 各位兄台,如何在Delphi7中整合Crystal Reports9?十分着急
- 拿到《borland传奇》了!散分!
- 天然呆纯门外汉问个DELPHI问题
- 这个问题很容易拿分的
- 排序代码错误,help!在线给分
- 如何实现拖拽效果
while not ADOQuery1.Eof do
Delete;
adoquery1.sql.clear;
adoquery1.sql.add('delete from tablename');
adoquery1.excute;
CREATE TABLE mytable() hehe!
arFiltered Only deletes records accessible through the current filter.
arAll Deletes all records in the recordset.
arAllChapters Deletes records in all chapters (ADO chapters)
Thank you for asking me for help .
adoquery1.sql.clear;
adoquery1.sql.add('delete from tablename');
adoquery1.open;
出现以下的错误,怎么回事呢?/??
project buding.exe raised exeption class eddatabaseerror
with message 'aodquery1:commandtext does not returm a result
set',process stopped , use step or run to continye
老师们!!!
改为adoquery1.execSQL;就可以了
open是需要返回值的,而
execSQL不需要。
但open也能执行过去,你执行一次就会发现该表中的记录已删除!
adoquery1.sql.clear;
adoquery1.sql.add('delete from tablename');
adoquery1.excute;
adoquery1.sql.clear;
adoquery1.sql.add('delete from tablename');
adoquery1.execsql 出现这样的错误
project buding.exe raised exception class eaccessviolation
with message 'access violation at address 1f487cab in module
'maado15.dll ' .write of address 02ba8008'.process stopped
use step or run to continue
没有 excute
ADOQuery1.sql.add('TRUNCATE TABLE mytable')
ADOQuery1.ExecSql
Now look for online help of Delphi please.You can get the result by yourself.
猜测:是否TADOQuery不支持,使用Supports方法看看。
具体看帮助。