林
林枫
Unregistered / Unconfirmed
GUEST, unregistred user!
我在插入数据时,总是提示如下错误:
'Key violation'
代码是:
procedure TForm2.Button1Click(Sender: TObject);
begin
with form1.query1 do
begin
close;
sql.clear;
sql.Add('insert into ibook(地址)');
sql.add('valuesss)');
unprepare;
parambyname('ss').asstring:=edit1.text;
execsql;
open;
end;
end;
怎么解决呢?
'Key violation'
代码是:
procedure TForm2.Button1Click(Sender: TObject);
begin
with form1.query1 do
begin
close;
sql.clear;
sql.Add('insert into ibook(地址)');
sql.add('valuesss)');
unprepare;
parambyname('ss').asstring:=edit1.text;
execsql;
open;
end;
end;
怎么解决呢?