ALTER USER
名称
ALTER USER -- 修改一个数据库角色
语法
ALTER USER name [ [ WITH ] option [ ... ] ]
这里 option 可以是:
SUPERUSER | NOSUPERUSER
| CREATEDB | NOCREATEDB
| CREATEROLE | NOCREATEROLE
| CREATEUSER | NOCREATEUSER
| INHERIT | NOINHERIT
| LOGIN | NOLOGIN
| CONNECTION LIMIT connlimit
| [ ENCRYPTED | UNENCRYPTED ] PASSWORD 'password'
| VALID UNTIL 'timestamp'
ALTER USER name RENAME TO newname
ALTER USER name SET configuration_parameter { TO | = } { value | DEFAULT }
ALTER USER name RESET configuration_parameter
兼容性
The ALTER USER 语句是 PostgreSQL 扩展。SQL 标准将用户的定义交给实现完成。