2 doc/src/sgml/ref/alter_user.sgml
3 PostgreSQL documentation
6 <refentry id="SQL-ALTERUSER">
8 <refentrytitle>ALTER USER</refentrytitle>
9 <manvolnum>7</manvolnum>
10 <refmiscinfo>SQL - Language Statements</refmiscinfo>
14 <refname>ALTER USER</refname>
15 <refpurpose>change a database role</refpurpose>
18 <indexterm zone="sql-alteruser">
19 <primary>ALTER USER</primary>
24 ALTER USER <replaceable class="PARAMETER">name</replaceable> [ [ WITH ] <replaceable class="PARAMETER">option</replaceable> [ ... ] ]
26 <phrase>where <replaceable class="PARAMETER">option</replaceable> can be:</phrase>
28 SUPERUSER | NOSUPERUSER
29 | CREATEDB | NOCREATEDB
30 | CREATEROLE | NOCREATEROLE
31 | CREATEUSER | NOCREATEUSER
34 | REPLICATION | NOREPLICATION
35 | CONNECTION LIMIT <replaceable class="PARAMETER">connlimit</replaceable>
36 | [ ENCRYPTED | UNENCRYPTED ] PASSWORD '<replaceable class="PARAMETER">password</replaceable>'
37 | VALID UNTIL '<replaceable class="PARAMETER">timestamp</replaceable>'
39 ALTER USER <replaceable class="PARAMETER">name</replaceable> RENAME TO <replaceable>new_name</replaceable>
41 ALTER USER <replaceable class="PARAMETER">name</replaceable> SET <replaceable>configuration_parameter</replaceable> { TO | = } { <replaceable>value</replaceable> | DEFAULT }
42 ALTER USER <replaceable class="PARAMETER">name</replaceable> SET <replaceable>configuration_parameter</replaceable> FROM CURRENT
43 ALTER USER <replaceable class="PARAMETER">name</replaceable> RESET <replaceable>configuration_parameter</replaceable>
44 ALTER USER <replaceable class="PARAMETER">name</replaceable> RESET ALL
49 <title>Description</title>
52 <command>ALTER USER</command> is now an alias for
53 <xref linkend="sql-alterrole">.
58 <title>Compatibility</title>
61 The <command>ALTER USER</command> statement is a
62 <productname>PostgreSQL</productname> extension. The SQL standard
63 leaves the definition of users to the implementation.
68 <title>See Also</title>
70 <simplelist type="inline">
71 <member><xref linkend="sql-alterrole"></member>