Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL Passthrough results
Message
From
06/01/2004 13:01:25
 
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00863999
Message ID:
00864251
Views:
13
>>
>Similarly, "SELECT @@ERROR" would return the error code of the last command (zero, if it was successful).
>>
>
>The only way to trap @@error is to encapsulate the call into a stored procedure. Rendering a sql insert and/or delete from the client will not provide an opportunity to trap and deal with the error.
>
>Also, subsequent calls to get @@rowcount are not reliable and ineffecient since you are 1 - not in the original tx and 2 - you have to make another trip to the server when 1 should suffice.

Can't you just send a batch like:

UPDATE whatever....
SELECT @@error errnum, @@rowcount rowcount

Which would return a cursor that contained the info?

BOb
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform