Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Batch updating in ADO
Message
From
18/12/2001 13:28:34
 
 
To
14/12/2001 01:04:00
General information
Forum:
Visual Basic
Category:
Database DAO/RDO/ODBC/ADO
Miscellaneous
Thread ID:
00594186
Message ID:
00595732
Views:
21
Thanks JC. Actually, I though about this little more and is thinking about running the code in the server dll instead.

However, this poses a new problem: If I have a server component process this long running process how do I code it so that the client app know what the server component is doing - basically a status/progress update and/or notification that the process is complete?.

I find that using the normal Dim WithEvents statement on the client doesn't
work. Am I doing something wrong or can it be done at all?


>Something like this should work, just make sure that the recordset to be populated is obtained from the original table with something like "Select * From myTable Where 1=0". This assures that you have all of the table info for the batch update. Although I don't believe you can do a keyset type cursor here. I have used static cursors for batch updating and they work fine.
>
>So your code above could change as follows:
>
Set rsLGO = New Recordset
>With rsLGO
>   .CursorLocation = adUseClient
>   .LockType = adLockBatchOptimistic
>   .CursorType = adOpenStatic
>   .Open myConnection, "Select * From myTable Where 1=0"
>End With
>After adding rows the UpdateBatch method should work as advertised. HTH
It's "my" world. You're just living in it.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform