数据更新问题,请进!

zapzap 2003-10-15 05:12:41
帮我看一下这个错误呀
我想让在删除一个表的一条条记录之前,先把另一个表的记录更新,出现了错误


原代码是这样的:

<!--#include file="conn1.asp"-->
<%
id=trim(request("id"))
if id<>"" then
set rs=server.createobject("adodb.recordset")
rs.open"select* from fenpei where id="&id,con,1,3
if rs.eof then
response.write"have no!"
response.end
con.close
else
shuliang=rs("shuliang")
intrname=rs("intrname")

sql="update introduction set shengyu=shengyu"&+shuliang&" where intrname='"&intrname&"'"
(错误行)  con.execute sql
rs.delete
rs.update
response.write"删除成功!"
response.write"修改成功!"
con.close
end if
else
response.write"不能为空!"
response.end
end if
%>
...全文
68 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
xupiao 2003-10-16
  • 打赏
  • 举报
回复
sql="update introduction set shengyu=(shengyu+"&shuliang&") where intrname='"&intrname&"'"
dafei0320 2003-10-16
  • 打赏
  • 举报
回复
一个字段要秒加()

sql="update introduction set shengyu=(shengyu+"&shuliang&") where intrname='"&intrname&"'"
con.execute(sql)
angelheavens 2003-10-15
  • 打赏
  • 举报
回复
sql="update introduction set shengyu=(shengyu+"&shuliang&") where intrname='"&intrname&"'"
con.execute(sql)

28,390

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧