Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to execute sp returning rs and has action queries al
Message
De
11/09/2001 21:59:00
 
 
À
10/09/2001 02:08:37
Information générale
Forum:
Visual Basic
Catégorie:
Bases de données DAO/RDO/ODBC/ADO
Divers
Thread ID:
00554375
Message ID:
00555347
Vues:
17
>Thanks for replying
>It seems that it is storing all the result sets in the recordset object and you need to go through a loop to cycle using NextRecordset
>but What I want exactly is to get the last result only in the recordset object
>not multiple recordsets.
>Your reply is highly appreciated
>Ibrahim

If you could put the statements into a stored procedure, not only would it speed up your code, but you could also use the following option at the beginning of the stored procedure so that only the results of the SELECT are returned:
Set NoCount ON
If not, you can simply add this statement to your SQL string, and it should also work.

What happens is that when you make an update, it's results ("(x) rows affected by the last query", for example) become the first "Recordset", even though it is not a recordset. SET NOCOUNT ON tells the SQL server not to return such information.

Hope this helps.
Andres M. Chiriboga, MCSE, MCP+I
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform