Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to return a cursor from sproc?
Message
 
General information
Forum:
Microsoft SQL Server
Category:
Stored procedures, Triggers, UDFs
Environment versions
SQL Server:
SQL Server 2005
Miscellaneous
Thread ID:
01163962
Message ID:
01163976
Views:
11
This message has been marked as a message which has helped to the initial question of the thread.
>>No. A stored procedure will return a separate recordset for each SELECT which doesn't store data in the local variables. IOW, a stored procedure may return multiple record sets.
>>
>
>Thank you. But how do I declare in my VFP code that calls a sproc that the sproc will return a record set?

There's nothing to declare in VFP. If you're using SPT then 3rd parameter in SQLEXEC() will specify the name of the first cursor returned. The second and so on cursors will have the same name with sequential number added. For example, SQLEXEC(lnConn, "EXEC mysp", "crsRes"). The second cursor returned will be 'crsRes1', the third 'crsRes2', etc
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform