asp编写文件时候出现错误
<!--#include file=../Connections/conn.asp-->
<%
dim sql
dim rs
dim username
dim password
username=replace(trim(Request("username")),"'","")
password=replace(trim(Request("password")),"'","")
set rs=Server.CreateObject("ADODB.Recordset")
sql="select * from user where password='"&password&"' and username='"&username&"'"
rs.open sql,conn,1,1
if rs("Enabled")=false then
response.Redirect("index.asp")
end if
if not(rs.bof and rs.eof) then
if password=rs("password") then
session("admin")=rs("username")
session("purview")=rs("purview")
session.Timeout=120
rs.close
set rs=nothing
call CloseConn()
Response.Redirect "manage.asp"
end if
end if
rs.close
set rs=nothing
call CloseConn()
%>
测试的时候出现:
ADODB.Recordset 错误 '800a0bb9'
参数类型不正确,或不在可以接受的范围之内,或与其他参数冲突。
rs.open sql,conn,1,1也就是这一行报错,怎么回事啊