Go to Glossary Search VisualAge C++ Help Go to VisualAge C++ Help Home Page Go to WWW VisualAge C++ Site

Add/Modify Stored Procedure Call Notebook

The Add/Modify Stored Procedure Call notebook allows you to add or modify a user-defined method that calls a database stored procedure. The method is added to the generated <class> or <class>Manager class, depending on what it returns. If the stored procedure call returns a result set from the table, then the method is added to the <class>Manager class; define this type of stored procedure call by launching this notebook from the Manager Methods dialog. Otherwise, if the stored procedure returns anything else, then the method is added to the <class> class; define this type of stored procedure call by launching this notebook from the Methods dialog.

The notebook has the following pages. Select a link to see details for the corresponding page:

Select the appropriate tab to move around the notebook. The following buttons appear at the bottom:

Stored Procedure Page
The Stored Procedure page lets you enter a name and an Stored Procedure name to define the method. It contains the following elements:

Parameter Page
The Parameter page lets you map method parameters from the stored procedure definition to corresponding parts of the C++ method, and to C++ types. Each parameter is displayed in the Parameters container, and is modified by changing the fields below. Work with one parameter at a time by selecting one, making the desired changes, and clicking the Modify button when you are done; then, select the next parameter.

Use the Mapped To radio buttons to modify the parameter mapping. There are four radio buttons for selecting what part of the method the parameter is mapped to. Only those options that are applicable to the parameter type are enabled. Select one of the following:

Click the Modify button when you are done with a parameter.

Comment Page
The Comment page lets you enter a comment for the user-defined method. The comment will be added to the generated code along with the method's C++ code.



User-Defined Methods


Define Stored Procedures
Display the List of Defined Stored Procedures


Sample: Create and Use a Stored Procedure Call on a Persistent Object