some problem about access database in ASP site

JEFFzuo 2003-10-17 02:29:07
I'm not a web developer, but my classmate want me to create a bbs for them, so I download a sample.
when I use it, some problem appeared. the information is refered by IE:

Microsoft JET Database Engine (0x80004005)
Operation must use an updateable query.
/our_bbs2/inc/char.asp, line 236

in the file, code is the following:

set rs=conn.execute(sql)
if rs.eof and rs.bof then
ComeFrom=""
actCome=""
sql="insert into online(id,username,userclass,ip,startime,lastimebk,boardid,browser,stats,actforip,UserGroupID,actCome,userhidden) values ("&statuserid&",'客人','客人','"&Request.ServerVariables("REMOTE_HOST")&"',Now(),Now(),"&boardid&",'"&Request.ServerVariables("HTTP_USER_AGENT")&"','"&replace(stats,"'","")&"','"&Request.ServerVariables("HTTP_X_FORWARDED_FOR")&"',7,'"&actCome&"',"&userhidden&")"
else
sql="update online set lastimebk=Now(),boardid="&boardid&",stats='"&replace(stats,"'","")&"' where id="&cstr(session("userid"))
end if
conn.execute(sql)

Someone can answer my problem?
...全文
32 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
JEFFzuo 2003-10-17
  • 打赏
  • 举报
回复
I think this problem is not wrong of source code, because i download other project, same problem is appearance. Help!!
tigerwen01 2003-10-17
  • 打赏
  • 举报
回复
try:
rs.open sql,conn,1,3
angelheavens 2003-10-17
  • 打赏
  • 举报
回复
HeHe...,English is too bad!

I hope that you can try it:
id="&cstr(session("userid"))

but below sentence modify:
id='"&cstr(trim(session("userid")))&"'"
qdubit 2003-10-17
  • 打赏
  • 举报
回复
程序提示char.asp的第236行有问题呀,请问236行是什么呀?

28,390

社区成员

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

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