求大神帮个忙,问题我也说不清楚,进来帮忙看一下吧
我有一个asp+mssql的程序,想添加一个会员收入排行,找到作者要了他的页面文件,可是不知道怎么用,直接覆盖的话在排行榜的位置那显示ADODB.Recordset 错误 '800a0cc1'
在对应所需名称或序数的集合中,未找到项目。
/index.asp,行 170
在对应所需名称或序数的集合中,未找到项目。
/index.asp,行 170
是不是要在数据库里添加个表啊什么的才行?求大神解答,
这是index.asp里面排行榜的源码,大神帮忙看一下,谢谢
程序代码:
<h3>推荐人数排行榜</h3> </div> <table width="100%" border="0" cellpadding="0" cellspacing="0" > <% set rs=server.createobject("adodb.recordset") sqls="select * from userlist order by id desc" rs.open sqls,conn,1,3 If Not rs.eof Then Do While Not rs.eof rs("totaltj")=0 rs("monthtj")=0 rs.update rs.movenext loop End if set rs=server.createobject("adodb.recordset") sqls="select * from userlist order by id desc" rs.open sqls,conn,1,3 If Not rs.eof Then Do While Not rs.eof set rs2=server.createobject("adodb.recordset") sqls="select * from userlist where formuser='"&rs("username")&"' " rs2.open sqls,conn,1,1 If Not rs2.eof Then rs("totaltj")=rs2("totaltj")+1 End If set rs2=server.createobject("adodb.recordset") sqls="select * from userlist where formuser='"&rs("username")&"' and regtime>='"&DateAdd("d",-30,Date())&"' and regtime<='"&DateAdd("d",1,Date())&"' " rs2.open sqls,conn,1,1 If Not rs2.eof Then rs("monthtj")=rs2("monthtj")+1 End if rs.update rs.movenext loop End if %> <td align="center" height=20 >排名</td> <td align="center" >用户</td> <td align="center" >当月推荐</td> <td align="center" >总推荐</td> <% set rss=server.createobject("adodb.recordset") sqls="select top 10 * from userlist order by totaltj desc" rss.open sqls,conn,1,1 i = 0 do while not rss.eof i = i + 1 %> <tr bgcolor=""> <td align="center" height=20><%=i%></td> <td align="center" ><%=rss("username")%></td> <td align="center" ><%=rss("monthtj")%></td> <td align="center" ><%=rss("totaltj")%></td> </tr> <% rss.movenext loop rss.close %> </table> </div> </div> <div class="right w235"> <div class="listbox"> <div class="title"> <h3>当前金币排行</h3> </div> <table width="100%" border="0" cellpadding="0" cellspacing="0" > <td align="center" height=20 >排名</td> <td align="center" >用户</td> <td align="center" >当月收入</td> <td align="center" >总收入</td> <% set rss=server.createobject("adodb.recordset") sqls="select top 10 * from userlist order by jifen desc" rss.open sqls,conn,1,1 i = 0 do while not rss.eof i = i + 1 %> <tr bgcolor=""> <td align="center" height=20><%=i%></td> <td align="center" ><%=rss("username")%></td> <td align="center" ><% set rs=server.createobject("adodb.recordset") sql="select sum(jifen) from jifenlist where userid="&rss("id")&" and time>='"&DateAdd("d",-30,Date())&"' and time<='"&DateAdd("d",1,Date())&"' " rs.open sql,conn,1,1 If Not rs.eof Then response.write rs(0) Else response.write "0" End if%></td> <td align="center" ><%=rss("jifen")%></td> </tr> <% rss.movenext loop rss.close %> </table> </div> </div>