大家帮我看看这个怎么搞,平时都好好的,这两天就打不开了,OLE DB Provider for SQL Server 错误 '80040e21'
Microsoft OLE DB Provider for SQL Server 错误 '80040e21'
多步 OLE DB 操作产生错误。如果可能,请检查每个 OLE DB 状态值。没有工作被完成。
/html/Car_Comment.asp,行 92
-----------上面是页面错误提示---------------------------
92是下面代码open sql语句那句,,我的sql语句应该没错,平时都用好好的,
sql 数据 microsoft sql?server
<%
sql="select * from Ht_Car_Comment where 1=1"
if searchtype =1 then
sql = sql & " and Datediff(d,PostTime,'"&now&"')=0"
end if
if BrandID<>0 then
sql = sql & " and BrandID="&BrandID
end if
if SerialID <>0 then
sql = sql & " and SerialID ="& SerialID
end if
if keyword<>"" then
sql=sql & " and "&strField&" like '%" & keyword & "%' "
End if
sql=sql & " order by CommentID desc"
Set rs= Server.CreateObject("ADODB.Recordset")
Rs.open sql,conn,1,1
if Rs.eof and Rs.bof then
Response.Write "<tr class=""tdbg""><td colspan=""6"" align=""center"" style=""height:80px"">暂无数据!</td></tr>"
else
TotalPut = Rs.RecordCount
If TotalPut mod MaxPerPage > 0 Then
TotalPage = TotalPut\MaxPerPage + 1
Else
TotalPage = TotalPut\MaxPerPage
End If
if CurrentPage > TotalPage Then CurrentPage = TotalPage
if CurrentPage < 1 then CurrentPage = 1
if CurrentPage>1 then rs.move (CurrentPage-1)*MaxPerPage
Do while not rs.eof
InfoID = Rs("CommentID")
%>