Error: Data provider or other service returned an E_FAIL status

Error: Data provider or other service returned an E_FAIL status

am 27.09.2005 08:32:28 von dave

Hi
I'm getting following error sometimes..Problem is error doesnt come up
everytime so its hard to figure out..

Microsoft Cursor Engine error '80004005'
Data provider or other service returned an E_FAIL status.

Below is my code snippet...

sql = "Select * from tblDetailLogs"
set tp = database.executequery1(sql,3,3)
for i = 1 to 10
tp.addnew
summaryofvisit = "tx_"&i&"_svisit"
followuprequired = "tx_"&i&"_foreq"
followupdate = "tx_"&i&"_fodt"
sendboard = "chk_"&i&"_board"
tp("DailyVisitLogID") = dailyvisitid
tp("GroupID") = i
tp("SummaryOfVisit") = request.Form(summaryofvisit)
tp("Followuprequired") = request.Form(followuprequired)
tp("Followuprequired") = request.Form(followuprequired)
tp("SendToBoard") = request.Form(sendboard)
if trim(request.Form(followupdate)) <> "" Then
tp("FollowupDate") = request.Form(followupdate)
end if
tp.update
next
set tp = nothing

After trying to found solution, I came up by that its not coding problem
but its because of
MDAC component installed on web server and ADO librarry are not most recent.

Any one had encounterd same problem?? Is there could be any other reason tht
cause an error?
Most of the time code works fine but some times it throws an error..
any help would be appreciated!!
Thanking you...
dave

Re: Error: Data provider or other service returned an E_FAIL status

am 27.09.2005 11:47:54 von reb01501

dave wrote:
> Hi
> I'm getting following error sometimes..Problem is error doesnt come up
> everytime so its hard to figure out..
>
> Microsoft Cursor Engine error '80004005'
> Data provider or other service returned an E_FAIL status.

You have not supplied enough information to enable us to help. What database
are you using? What OLE DB provider are you using? Which line of code causes
the error? What's in that executequery1() function? Is "database" a custom
component? An ASP class? What is it?

General comments that probably have nothing to do with your problem:
1. Avoid selstar in production code - http://www.aspfaq.com/show.asp?id=2096
2. Avoid using cursors to update data - use DML (UPDATE, INSERT, DELETE)
statements instead.



>
> After trying to found solution, I came up by that its not coding
> problem

How have you come to this conclusion?

> but its because of
> MDAC component installed on web server and ADO librarry are not most
> recent.

So, have you corrected this issue?



--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"