1ALTER USER(7)            PostgreSQL 13.3 Documentation           ALTER USER(7)
2
3
4

NAME

6       ALTER_USER - change a database role
7

SYNOPSIS

9       ALTER USER role_specification [ WITH ] option [ ... ]
10
11       where option can be:
12
13             SUPERUSER | NOSUPERUSER
14           | CREATEDB | NOCREATEDB
15           | CREATEROLE | NOCREATEROLE
16           | INHERIT | NOINHERIT
17           | LOGIN | NOLOGIN
18           | REPLICATION | NOREPLICATION
19           | BYPASSRLS | NOBYPASSRLS
20           | CONNECTION LIMIT connlimit
21           | [ ENCRYPTED ] PASSWORD 'password' | PASSWORD NULL
22           | VALID UNTIL 'timestamp'
23
24       ALTER USER name RENAME TO new_name
25
26       ALTER USER { role_specification | ALL } [ IN DATABASE database_name ] SET configuration_parameter { TO | = } { value | DEFAULT }
27       ALTER USER { role_specification | ALL } [ IN DATABASE database_name ] SET configuration_parameter FROM CURRENT
28       ALTER USER { role_specification | ALL } [ IN DATABASE database_name ] RESET configuration_parameter
29       ALTER USER { role_specification | ALL } [ IN DATABASE database_name ] RESET ALL
30
31       where role_specification can be:
32
33           role_name
34         | CURRENT_USER
35         | SESSION_USER
36

DESCRIPTION

38       ALTER USER is now an alias for ALTER ROLE (ALTER_ROLE(7)).
39

COMPATIBILITY

41       The ALTER USER statement is a PostgreSQL extension. The SQL standard
42       leaves the definition of users to the implementation.
43

SEE ALSO

45       ALTER ROLE (ALTER_ROLE(7))
46
47
48
49PostgreSQL 13.3                      2021                        ALTER USER(7)
Impressum