Stored procedures are one of the most effective ways to manage and protect complex relational databases. They play a vital role in systems that support large databases, large numbers of users, or both. Using stored procedures, you can protect critical data from random access, those with malicious intent, and those with innocent intent but destructive tendencies. In many sites, stored procedures are the only way to access or update data — access to base tables is strictly prohibited.
One of the most powerful and important features of RDO is its ability to execute and manage the results returned by stored procedures, regardless of their complexity. The following topics discuss how to best use this feature.
Stored procedures usually require one or more parameters, and while some stored procedures return rows, not all do. RDO provides a number of ways to handle these variations; however, if you must capture the stored procedure return status or output parameters, you must use the ODBC CALL syntax as described in "Creating RDO Parameter Queries."
A stored procedure can return any number of result sets — and stored procedures can invoke other stored procedures. Your code needs to be prepared to manage all of these result sets, some containing rows, some just returning parameters, some returning only the number of rows affected, and some all three.