没人知道? 完整出错信息是:commandtext does not return a result set
Adodataset的commandtext中只能用select语句,帮助中说的很明白。
Use the TADODataSet component's CommandText property to retrieve the dataset, specifying either a table name or an SQL statement (SELECT only). TADODataSet is not capable of issuing Data Manipulation Language (DML) SQL statements that do not return result sets (like DELETE, INSERT, and UPDATE). For this use a component like TADOCommand or TADOQuery.用adoquery adoquery1.close; adoquery1.sql.clear; adoquery1.sql.add('insert into service(......)'); adoquery1.excute; //注意不返回结果集 不要open 否则要open
完整出错信息是:commandtext does not return a result set
adoquery1.close;
adoquery1.sql.clear;
adoquery1.sql.add('insert into service(......)');
adoquery1.excute; //注意不返回结果集 不要open 否则要open