error 800a0cb3: adLockPessimistic vs. adLockReadOnly
am 01.03.2007 22:58:17 von VanessaEveryone,
I have a long story, so please bear with me. Sorry~
Our web server and SQL server are located at the same machine (donât ask
whyâ¦..), and we are working on separating them recently. First our IT people
are going to move everything (both web and SQL server) to a new machine, then
clean up the original machine, and finally move just the web server back to
the original machine and finish the process.
Here is some SPEC of our new machine:
3.0 GHz Xeon Processor
4 GB of ram
IIS 6.0
SQL 2000 with SP3
However, we encounter problems right now at step 1 at the testing stage.
Our ASP scripts are working fine at the current server. But when we perform
testing on the new server, the ASPs are not working with following error:
ADODB.Recordset error '800a0cb3'
Current Recordset does not support bookmarks. This may be a limitation of
the provider or of the selected cursortype.
The scripts are just copied directly from the current server to the new
server (of course, the data source name is updated). Here is the sample
coding:
<%
page=request("page")
if page="" or not isNumeric(page) then page=1
iPageSize = 30
iPageCurrent=cint(page)
connectWord = "N"
strSQL = "SELECT * FROM CSheetDtl"
Set DataRec = Server.CreateObject("ADODB.RecordSet")
DataRec.PageSize = iPageSize
DataRec.CacheSize = iPageSize
DataRec.Open strSQL, DataConn, adOpenKeyset, adLockPessimistic, adCmdText
iPageCount = DataRec.PageCount
if iPageCurrent > iPageCount then iPageCurrent = iPageCount
if iPageCurrent < 1 then iPageCurrent = 1
if not iPageCount = 0 then
DataRec.AbsolutePage = iPageCurrent ï ERROR SHOWS ON THIS LINE
%>
ID | CSheet_ID |
<%=Datarec("ID")%> | <%=Datarec("CSheet_ID")%> |