L
lxh
Unregistered / Unconfirmed
GUEST, unregistred user!
Query1.CachedUpdates:=true;
for i:=0 to 10 do
begin
Query1.Close;
Query1.ParamByName('StockCode').Asstring:='01'+inttostr(i);
Query1.ParamByName('StockName').Asstring:='发展';
Query1.ParamByName('StockPY').Asstring:='sfz'+inttostr(i);
Query1.ParamByName('ExChange').AsInteger:=1;
Query1.ExecSQL;
end;
Query1.ApplyUpdates;
程序执行到ExceSQL时,就写了数据,根本没有缓冲。
执行ApplyUpdates时出错如下:
Dataset not in Edit or in insert mode.
for i:=0 to 10 do
begin
Query1.Close;
Query1.ParamByName('StockCode').Asstring:='01'+inttostr(i);
Query1.ParamByName('StockName').Asstring:='发展';
Query1.ParamByName('StockPY').Asstring:='sfz'+inttostr(i);
Query1.ParamByName('ExChange').AsInteger:=1;
Query1.ExecSQL;
end;
Query1.ApplyUpdates;
程序执行到ExceSQL时,就写了数据,根本没有缓冲。
执行ApplyUpdates时出错如下:
Dataset not in Edit or in insert mode.