Running a stored procedure (JSP)
With JSP pages, you must add a Callable server behavior to a page to run a stored procedure.
To add a stored procedure to a JSP page:
- In Dreamweaver, open the page that will run the stored procedure.
- In the Bindings panel (Window > Bindings), click the Plus (+) button and select Callable (Stored Procedure).
The Callable (Stored Procedure) dialog box appears.
- Complete the dialog box.
For instructions, click the Help button in the dialog box.
- Click OK.
After you close the Callable (Stored Procedure) dialog box, Dreamweaver inserts JSP code in your page that, when run on the server, calls a stored procedure in the database. The stored procedure in turn performs a database operation, such as inserting a record.
If the stored procedure takes parameters, you can create a page that gathers the parameter values and submits them to the page with the stored procedure. For example, you may create a page that uses URL parameters or an HTML form to gather parameter values from users.