Stored Procedures
The DB Access Module for Oracle OCI includes support for RWDBStoredProc that is analogous to PL/SQL procedures and functions. (See the Oracle PL/SQL Language Reference.) OCI call OCIDescribeAny() is used to get parameter information for procedures and functions. SQL statements are made to create procedures and functions, to get their text, and to execute them.
Note that PL/SQL differentiates between stored functions and procedures. PL/SQL functions cannot be created with the createProcedure() method of RWDBDatabase that we describe in the next section. Instead, you must use the executeSql() method of RWDBConnection. PL/SQL functions can be executed using class RWDBStoredProc and the return value can be obtained using RWDBStoredProc::returnValue().
NOTE: It is currently not possible to use RWDBStoredProc to encapsulate a PL/SQL procedure or function that has parameters of the Oracle datatypes CLOB and BLOB.