Oracle7 Server Administrator's Guide

Contents Index Home Previous Next

Renaming Schema Objects

To rename an object, you must own it. You can rename schema objects in either of the following ways:

If you drop and re-create an object, all privilege grants for that object are lost. Privileges must be re-granted when the object is re-created. Alternatively, a table, view, sequence, or a private synonym of a table, view, or sequence can be renamed using the RENAME command. When using the RENAME command, grants made for the object are carried forward for the new name. For example, the following statement renames the SALES_STAFF view:

RENAME sales_staff TO dept_30; 

Note: You cannot rename a stored PL/SQL program unit, public synonym, index, or cluster. To rename such an object, you must drop and re-create it.

Before renaming a schema object, consider the following effects:

See Also: For more information about how Oracle manages object dependencies, see [*].


Contents Index Home Previous Next