Rename Dependent Objects

When you rename objects, you must also change the text of any dependent procedure, trigger, or view, to reflect the new object name.

The original object name continues to appear in query results until you change the name of, and compile the procedure, trigger, or view. The safest course is to change the definitions of any dependent objects when you execute sp_rename. You can use sp_depends to get a list of dependent objects.

You can use the defncopy utility program to copy the definitions of procedures, triggers, rules, defaults, and views into an operating system file. Edit this file to correct the object names, then use defncopy to copy the definition back into SAP ASE. See the Utility Guide.