Valid in: SQL, ESQL
The Drop User statement deletes an existing user. To define a new user, use the create user statement. To change the characteristics of an existing user, use the alter user statement. For details about users, see the Database Administrator Guide.
Users that own databases cannot be dropped. If a user that owns database objects is dropped, the objects are not dropped.
The Drop User statement has the following format:
[EXEC SQL] DROP USER user_name;
You cannot use host language variables in an embedded Drop User statement.
You must have the maintain_user privilege and be connected to the iidbdb database.
The Drop User statement locks pages in the iiuser system catalog in the iidbdb.
The following example drops a user:
drop user betsy;