好像SQL语句有问题吧。
应该是
UPdate TableName
set FieldName = FieldValue , ...
where FieldName = FieldValue
应该是
UPdate TableName
set FieldName = FieldValue , ...
where FieldName = FieldValue
解决方案 »
- 求delphi资源管理器程序
- 如何把bitmap类型图片数据 存到 pchar类型变量中?
- 各位提供一点学习经验吧!!!!!!!!!!!!
- 高分求救!如何提高TClientDataSet的存储性能,在线等待中...
- 刷新表的时候提示it is not uniquely indexed?应该如何解决啊?
- Delphi.NET中的Object Pascal与Delphi6或7的OP相比会有变化么?
- 高手手请进!文本文件数据库表的问?急!!!!!!!!!!!!!!!!
- 怎样下载象http://www.abc.cn/down.asp?name=computer.doc这样的文件,delphi代码怎样写.
- 放在pageCONTROL上的DBMEMO,DBRICHEDIT会自动改变对齐方式?
- 我想用delphi编写一个类似excel的程序,请大家给一点建议,谢谢.
- 是否能使用dephi写服务程序?
- quickrep和query方面的问题?在线
with query1 do
begin
try
open;
sql.Clear;
sql.Add('update a_client_server_item ');
sql.add('set server_type=:aa,server_content=:bb,re=:cc,type_a=:a,type_b=:b,type_c=:c,type_d=:d,type_e=:e,type_f=:f,type_g=:g,type_h=:h ');
sql.add('where id ='+inttostr(query_id));
showmessage(sql.Text);
parambyname('aa').asstring:=combobox2.text;
parambyname('bb').asstring:=edit4.text;
parambyname('cc').asstring:=edit6.text;
parambyname('a').asboolean:=checkbox1.Checked;
parambyname('b').asboolean:=checkbox2.Checked;
parambyname('c').asboolean:=checkbox3.Checked;
parambyname('d').asboolean:=checkbox4.Checked;
parambyname('e').asboolean:=checkbox5.Checked;
parambyname('f').asboolean:=checkbox6.Checked;
parambyname('g').asboolean:=checkbox7.Checked;
parambyname('h').asboolean:=checkbox7.Checked;
execsql;
except
showmessage('更新出现错误(a_client_server_item)!');
cancel;
end;
end;
就会出现table read only的错误
去掉后正常
不过既然不用是正常的,那么就不用吧。
with query1 do
begin
close;
sql.Clear;
...
end;