我做分頁程式經常出現錯誤.如下;
ADODB.Recordset (0x800A0CB3)
Current Recordset does not support bookmarks. This may be a limitation of the provider or of the selected cursortype.
請教高手指點,謝謝先
...全文
189打赏收藏
分頁程式出現錯誤???急!!!
我做分頁程式經常出現錯誤.如下; ADODB.Recordset (0x800A0CB3) Current Recordset does not support bookmarks. This may be a limitation of the provider or of the selected cursortype. 請教高手指點,謝謝先
我用的是加1,3但在MYSQL中不行,在Oracle中可以,現在又碰到一個問題,如果我在查詢一個table可以分頁,但如果查詢兩個table,並在網頁上顯示兩個table中的部分資料,分頁就不行,只顯示第一頁,而且顯示總的記錄數和總頁數都為-1,請問哪位高手可以幫忙指點,謝謝先;
Set Conne = Server.CreateObject("ADODB.Connection")
conne.open "Driver={Microsoft ODBC For Oracle};server=dnisfis; uid=sfis; pwd=sfis"
Set RS=Server.CreateObject("ADODB.RecordSet")
sql= "select C.EMP,P.EMP_PASS,C.FUN,C.PRIVILEGE,C.PRG_NAME,P.EMP_NAME FROM SFIS1.C_PRIVILEGE C, SFIS1.C_EMP_DESC_T P WHERE C.EMP=P.EMP_NO order by C.EMP desc"
我以前用的sqlserver数据库分页没问题。里面的各种属性多支持。后来用sybase数据库就有问题了。因为里面也有好多的属性不支持。我给你看看我的代码。不是用asp里面的记录集等属性实现的。希望能给你帮助
<!--#INCLUDE FILE="data.asp" -->
<!--#INCLUDE FILE="check.asp" -->
<script>
function OpenWindows(url)
{
var
newwin=window.open(url,"_blank","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,top=50,left=120,width=600,height=400");
return false;
}
function OpenSmallWindows(url)
{
var
newwin=window.open(url,"_blank","toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,top=50,left=120,width=600,height=370");
return false;
dim page
page=request("page")
if page=0 then
page=1
end if
PageSize = 5
dim rs,strSQL,news
strSQL ="SELECT * FROM asp_calendar where userid="&session("Uid")&" ORDER BY id DESC"
Set rs = Server.CreateObject("ADODB.Recordset")
rs.open strSQL,Conn,3,3
if rs.eof then
response.write "<font class='3dfont'>还没有任何东东</font>"
else
'/////////////////////////////求出总记录数
sSql = "select Count(*) from asp_calendar where userid="&session("Uid")&" ORDER BY id DESC"
set MeetingSet = Server.CreateObject("ADODB.Recordset")
Set MeetingSet.ActiveConnection = Conn
<TD width=50> <b>状态</b> </TD>
</TR>
<%
'///////////显示每页的记录
count=0
For i = 1 to (Page-1)*PageSize
rs.MoveNext
next
if not rs.eof then
For i = 1 to pagesize