Editing Procedures or Functions

Previous
Previous
Next
Next

To edit procedures and functions, you can use the Object Browser page, the SQL Commands page, or the SQL CREATE OR REPLACE statement with SQL Command Line.

If you use the SQL CREATE OR REPLACE statement with SQL Command Line, you simply type in the modified procedure or function code. See "Entering and Executing SQL Statements and Commands".

To edit a procedure in the SQL Commands page:

  1. Log in to the Database Home Page. See "Logging in to the Database Home Page".

  2. On the home page, click the SQL icon to display the SQL page.

  3. Click the SQL Commands icon to display the SQL Commands page.

  4. Click the Saved SQL tab to display the saved SQL modules.

  5. Click the name of the saved SQL that contains the procedure or function code that you want to edit.

  6. Modify the source code for the procedure or function. Click the Run button if you want to execute the procedure or function.

  7. When you are finished, you can click the Save button to save the code for future use.

To edit a subprogram with Object Browser:

  1. Log in to the Database Home Page. See "Logging in to the Database Home Page". To run the examples in this guide, log in as user HR with your password for the HR account.

  2. Click the Object Browser icon on the Database Home Page.

    The Object Browser home page appears.

  3. Select Procedures or Functions in the object list, then click the subprogram you want to display.

  4. With the subprogram displayed, click Edit button to modify the subprogram code.

  5. Click the Compile button to ensure your changes did raise any errors when executed. Compiling the subprogram also saves the changes.