Microsoft JET Database Engine 错误 '80040e09'

来源:百度知道 编辑:UC知道 时间:2024/07/02 02:17:16
请高手指点

第一个问题
Microsoft VBScript 编译器错误 错误 '800a03f6'

缺少 'End'

/iisHelp/common/500-100.asp,行242

Microsoft JET Database Engine 错误 '80040e09'

不能更新。数据库或对象为只读。

/shunhong/TMP8jmgh8i362.asp,行5

第二个问题

链接数据库代码:
<%
set conn=server.createobject("adodb.connection")
path=server.mappath("data/www.moveidc.com.mdb")
conn.open"provider=microsoft.jet.oledb.4.0;data source="&path
%>

浏览执行下面代码
<!--#include file="conn.asp"-->
<%
conn.execute "update xinwen set dian=dian+1 where id="&request("id")
set rs2=server.createobject("adodb.recordset")
rs2.open "select top 1 * from xinwen where id="&request("id"),conn,3
%>
<%
n=3
%

<%
conn.execute "update xinwen set dian=dian+1 where id="&request("id")
set rs2=server.createobject("adodb.recordset")
sql="select top 1 * from xinwen where id="&request("id")&""
rs2.open sql,conn,1,3
%>

第一个问题:
你的程序中有一个if 语句没有End if,或者没有End Sub或End Function,关于数据库或对象为只读这个问题,可能与你Windows用户有关,也可能是打开记录集的游标错误,就用rs.open sql,conn,1,3或rs.open sql,conn,3,3

第二个问题:
缺少 'End' 与第一个问题一样,错误语句可能在conn.asp中;
request("id")的值为空或Null