Viewing and editing source code and properties for DB2 routines

You can use the Properties window to edit the properties of a routine, such as a stored procedure or user-defined function. You can also edit the source code for a routine. If you make changes in your local Data Definition view to the source code of a routine, save the routine and rebuild it onto the DB2 database server to apply the changes to the server version.

Restriction: In the Database Explorer view, you can view routine properties but you cannot change them.

To edit the properties or source code of a DB2 routine:

  1. Switch to the Data perspective.

  2. In the Data Definition view, double-click a routine. The editor displays the source code of the routine.

  3. Edit the source code as required.

  4. Click one of the tabs at the bottom of the editor to display the routine's properties. If a property is available to edit, it is displayed in a field with a white background. If it is not available to edit, it is displayed in a field with a gray background. The only user-defined function (UDF) property that you can edit is the comment.

  5. Make the desired changes, and click File > Save.

The properties or source code of the routine are changed.

 

Related tasks

Dropping routines from a DB2 database
Deleting routines from a project