使用adoconnection连接,中间我启动了事务。adotable进行数据提交的时候,第一次table.post正常,第二次table.post报这个错误。
具体代码
try
adoconnection.begintrans;
table.append;
.....具体赋值操作table.fields[i].asstring:=......
if 满足条件 then
table.post
else
table.cancel;
adoconnection.committrans
except
table.cancel;
adoconnection.rollbacktrans;
end;
有没有人见过这个错误啊?
具体代码
try
adoconnection.begintrans;
table.append;
.....具体赋值操作table.fields[i].asstring:=......
if 满足条件 then
table.post
else
table.cancel;
adoconnection.committrans
except
table.cancel;
adoconnection.rollbacktrans;
end;
有没有人见过这个错误啊?
try
table.append;
.....具体赋值操作table.fields[i].asstring:=......
if 满足条件 then
table.post
else
table.cancel;
except
table.cancel;
adoconnection.rollbacktrans;
end;
adoconnection.committranstry it!