Entering content frame

DROP USER Statement (drop_user_statement) Locate the document in its SAP Library structure

The DROP USER statement (drop_user_statement) drops a database user definition. The metadata of the database user to be dropped is dropped from the database catalog.

Syntax

<drop_user_statement> ::= DROP USER <user_name> [<cascade_option>]

Explanation

The current database user must have owner authorization over the database user to be dropped.

The specified database user must not be logged on to the database system when the DROP USER statement is executed.

Dropping a user with the database user class DBA does not affect any database users that were created by this user. The database system administrator (SYSDBA user) becomes the new owner of these database users.

<cascade_option>

·        If the database user to be dropped does not belong to a user group and is the owner of synonyms or tables, and if the CASCADE option RESTRICT was specified, the DROP USER statement fails.

·        If no CASCADE option or the CASCADE option CASCADE was specified, all the schemas, synonyms, and tables of the database user to be dropped are also dropped, along with any indexes, privileges, view tables, and so on based on them.
Any database objects that the database user to be dropped generated in schemas belonging to different users are retained. The owner of the schema in question becomes the new owner of such objects.

 

Leaving content frame