Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
RETURN_VALUE in ADO
Message
General information
Forum:
Microsoft SQL Server
Category:
Stored procedures, Triggers, UDFs
Miscellaneous
Thread ID:
00558025
Message ID:
00558697
Views:
14
>>How can I retrieve from, say FoxPro, the value returned by a stored procedure? Under SQL Server 7.0, the command was simply:
>>
>>lnResult = oCommand.Parameters('RETURN_VALUE').Value
>>
>>In SQL 2000, RETURN_VALUE is no longer recognized.
>>
>>Thank you,
>
>Haven't tested this, but in SQL 7 you could get to the return value by looking at parameter 0 of the collection. This is always the first parameter in the collection. So try replacing the code with:
>
lnResult = oCommand.Parameters(0).Value
>HTH

Thank you. Your suggestion worked as well.

As per mskb#Q285295, the new command is:
lnResult = oCommand.Parameters('@RETURN_VALUE').Value
or:
lnResult = oCommand.Parameters(0).Value
will also work.
Aristotle
Previous
Reply
Map
View

Click here to load this message in the networking platform