🔥码云GVP开源项目 12k star Uniapp+ElementUI 功能强大 支持多语言、二开方便! 广告
# ALTER USER ## Name ALTER USER -- 修改一个数据库角色。 ## Synopsis ``` ALTER USER _name_ [ [ WITH ] _option_ [ ... ] ] where `_option_` can be: SUPERUSER | NOSUPERUSER | CREATEDB | NOCREATEDB | CREATEROLE | NOCREATEROLE | CREATEUSER | NOCREATEUSER | INHERIT | NOINHERIT | LOGIN | NOLOGIN | REPLICATION | NOREPLICATION | CONNECTION LIMIT _connlimit_ | [ ENCRYPTED | UNENCRYPTED ] PASSWORD '_password_' | VALID UNTIL '_timestamp_' ALTER USER _name_ RENAME TO _new_name_ ALTER USER _name_ SET _configuration_parameter_ { TO | = } { _value_ | DEFAULT } ALTER USER _name_ SET _configuration_parameter_ FROM CURRENT ALTER USER _name_ RESET _configuration_parameter_ ALTER USER _name_ RESET ALL ``` ## 描述 `ALTER USER`现在是[ALTER ROLE](#calibre_link-17)命令的别名(即两者相同)。 ## 兼容性 `ALTER USER`是PostgreSQL的扩展,SQL标准中还没有完成用户定义相关的语法。 ## 参见 [ALTER ROLE](#calibre_link-17)