ALTER USER

Alters settings associated with the user. There is only the default resource pool setting that can be changed.

Syntax

ALTER USER user[@host] [IDENTIFIED BY 'password'] SET DEFAULT RESOURCE POOL = poolname;

Arguments

user: The name of the user.

host: The host that the user can connect from. For example, specifying localhost means the user account can be used only when connecting from the local host. If no host is explicitly specified, the % wildcard will be used, which allows the user to connect from any host.

password: An optional database connection password.

poolname: The new default resource pool.

Examples

The following example demonstrates how to add a new user with a resource pool, and then change the resource pool.

CREATE USER joe WITH DEFAULT RESOURCE POOL = general;
ALTER USER joe SET DEFAULT RESOURCE POOL = executive;
Was this article useful?