mirror of
https://github.com/postgres/postgres.git
synced 2025-08-19 23:22:23 +03:00
Add missing ALTER USER variants
ALTER USER ... SET did not support all the syntax variants of ALTER ROLE ... SET. Reported-by: Pavel Golub <pavel@microolap.com>
This commit is contained in:
@@ -1111,12 +1111,20 @@ AlterUserStmt:
|
||||
|
||||
|
||||
AlterUserSetStmt:
|
||||
ALTER USER RoleSpec SetResetClause
|
||||
ALTER USER RoleSpec opt_in_database SetResetClause
|
||||
{
|
||||
AlterRoleSetStmt *n = makeNode(AlterRoleSetStmt);
|
||||
n->role = $3;
|
||||
n->database = NULL;
|
||||
n->setstmt = $4;
|
||||
n->database = $4;
|
||||
n->setstmt = $5;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
| ALTER USER ALL opt_in_database SetResetClause
|
||||
{
|
||||
AlterRoleSetStmt *n = makeNode(AlterRoleSetStmt);
|
||||
n->role = NULL;
|
||||
n->database = $4;
|
||||
n->setstmt = $5;
|
||||
$$ = (Node *)n;
|
||||
}
|
||||
;
|
||||
|
Reference in New Issue
Block a user