这段更新数据库的代码,有那边错了么,为什么提示UPDATE 语句的语法错误。

chqwork 2009-07-02 04:58:40
conn.execute "update webinfo set webname='" & trim(request("webname"))&"',webemail='" &trim(request("webemail")) &"',dizhi='" &trim(request("dizhi")) &"',youbian='" &trim(request("youbian")) &"',dianhua='" &trim(request("dianhua")) &"',copyright='" &trim(request("copyright")) &"',webbanner='" &trim(request("webbanner")) &"',weblogo='" &trim(request("weblogo"))&"',webbanner='" &trim(request("webbanner"))&"',guestuser='" &trim(request("guestuser"))&"',icp='" &trim(request("icp"))&"',qq='" &trim(request("qq"))&"',view='" &trim(request("view"))&"',des='" &trim(request("des"))&"',key='" &trim(request("key"))&"',sltype='" &trim(request("sltype")) &"',mailaddress='" &trim(request("mailaddress"))&"',mailsend='" &trim(request("mailsend"))&"',mailusername='" &trim(request("mailusername"))&"',mailuserpass='" &trim(request("mailuserpass"))&"',mailname='" &trim(request("mailname"))&"',webnow='" &trim(request("webnow"))&"',xwtype='" &trim(request("xwtype"))&"',webmess='" &trim(request("webmess"))&"',ksu='" &trim(request("ksu"))&"',csu='" &trim(request("csu"))&"',xinpin='" &trim(request("xinpin"))&"',tejia='" &trim(request("tejia"))&"',tuijian='" &trim(request("tuijian"))&"',probg='" &trim(request("probg"))&"',qqwz='" &trim(request("qqwz"))&"',dymail='" &trim(request("dymail"))&"',bbslogo='" &trim(request("bbslogo"))&"',pictype='" &trim(request("pictype"))&"',ordermail='" &trim(request("ordermail"))&"',regmail='" &trim(request("regmail"))&"'where id=3"
...全文
51 7 打赏 收藏 转发到动态 举报
写回复
用AI写文章
7 条回复
切换为时间正序
请发表友善的回复…
发表回复
ouyang3857116 2009-07-05
  • 打赏
  • 举报
回复
&trim(request("regmail"))&"'where id=3"
where前面没空格吧
&trim(request("regmail"))&"' where id=3"
Sandrer 2009-07-05
  • 打赏
  • 举报
回复
如果不是4楼所说的错误,也不是SQL本身格式错误的话,那么有可能是你数据库中的字段与数据库中的关键字同名
试试把每个字段用[]括起来看看!
chqwork 2009-07-02
  • 打赏
  • 举报
回复
是这个关系么
hookee 2009-07-02
  • 打赏
  • 举报
回复
如果字段是数字类型,值的两边去掉单引号.
chqwork 2009-07-02
  • 打赏
  • 举报
回复
找不出来么
jingxiaoping 2009-07-02
  • 打赏
  • 举报
回复
看得眼都花了,你先把sql语句单独写一下,然后用response.write sql输出到页面,再从页面把语句复制出来,扔到查询分析器里面一看就知道是怎么回事儿了。
lzp4881 2009-07-02
  • 打赏
  • 举报
回复
更新的字段如果很多,建议用rs.open

28,406

社区成员

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

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