|
-
Mar 8th, 2001, 11:41 AM
#1
Thread Starter
New Member
I have a vb application making use of a com dll to make connections to the database and executing stored procedures. one of the classes that i am using has a method which uses disconnected ado recordsets to return back the results after executing the stored procedure. i am getting an error timeout expired when executing a particular stored procedure. The Stored procedure is very complicated and data returned is also huge so it gives me an error only when the data returned back is huge say for 34000 records. i have also tried to increase the connection timeout to 360 but does not help. What could be the problem? here is my code...
Set cnnSupplierItems = CreateObject("ADODB.Connection")
Set rsSuppItems = CreateObject("ADODB.Recordset")
cnnSupplierItems.ConnectionTimeout = 360
cnnSupplierItems.Open "File Name=" & App.Path "\ESCatalog_datasource.udl"
strSQL = "{call sp_findsupplieritem("
strSQL = strSQL & "'" & Utility.RemoveSingleQuote(Trim(strSupplierItemNumber)) & "', "
..... builds the whole strsql string
rsSuppItems.CursorLocation = adUseClient
rsSuppItems.Open strSQL, cnnSupplierItems, adOpenDynamic, , adAsyncExecute
Do While (rsSuppItems.State = adStateExecuting) ...> 'goes to timeout error after a minute or so
Loop
any help would be appreciated
Thanks
Arati
-
Mar 8th, 2001, 11:55 AM
#2
Junior Member
Get rid of the Loop.
The stored Procedures are treated as in-process code so while retrieving the recordset it should not carry on running further code
-
Mar 16th, 2001, 09:27 AM
#3
Lively Member
hi Arti, I have a question about using COM Dlls for Database connection
hi Arti,
I am new to using COM objects.. what is the advantage of using COM Dll from VB to call stored procedures .. Is there any problem calling the
stored procedures from VB or ASP directly using ODBC
DSN ?
Do you recommend any sites that has more information
on creating DataBase connection Dlls and precautions to be taken while doing it..
thanks
sarath
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|