单击还书按钮就出现下面的这个错误,怎么解决? 急问啊!
错误类型:
Microsoft OLE DB Provider for ODBC Drivers (0x80040E07)
[Microsoft][ODBC Microsoft Access Driver] 标准表达式中数据类型不匹配。
/test/restore_book.asp, 第 11 行
下面是我的代码,高手指教一下,怎么改才能运行?
<link href="style.css" type="text/css" rel="stylesheet">
<!--#include file="conn.asp"-->
<%
if request("act")="del" then
db.execute("delete from msg where id="&request("id"))
response.write "<script>alert('编号为:"&request("id")&"消息删除成功!');window.location.href='readmsg.asp?uid="&request("uid")&"'</script>"
end if
%>
<%dim xx
xx=request("uid")
sql="select * from msg where uid="&xx&"" //第11行
set rs=db.execute(sql)
if rs.eof then
response.write "<script>alert('没有消息了!');history.go(-1)</script>"
else
%>
<table width="533" border="1">
<tr>
<td>消息id</td>
<td>消息内容</td>
<td width="33">操作</td>
</tr><%do while not rs.eof%>
<tr><td><%=rs("id")%></td>
<td><%=rs("content")%></td>
<td><a href="readmsg.asp?act=del&id=<%=rs("id")%>&uid=<%=xx%>">删除</a>
</td>
</tr>
<%rs.movenext
loop%>
</table></div><br>
<%end if%><div><a href="readmsg.asp?act=del_all&uid=<%=xx%>" target="right">删除所有消息</a> <a href="index.asp" target="right">首页</a>
<a href="javascript:history.go(-1)" target="right">返回</a>
</div>
<%if request("act")="del_all" then
db.execute("delete from msg where uid="&request("uid"))
response.write "<script>alert('已经删除所有消息!');history.go(-1)</script>"
end if%>