Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitc778e27

Browse files
committed
Correct query in pg_dumpall:dumpRoles
We need to use a new branch due to the 9.5 addition of bypassrlswhen adding in the clause to exclude pg_* roles from being dumpedby pg_dumpall.Pointed out by Noah, patch by me.
1 parenteccfeeb commitc778e27

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

‎src/bin/pg_dump/pg_dumpall.c

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -676,6 +676,16 @@ dumpRoles(PGconn *conn)
676676
"FROM pg_authid "
677677
"WHERE rolname !~ '^pg_' "
678678
"ORDER BY 2");
679+
elseif (server_version >=90500)
680+
printfPQExpBuffer(buf,
681+
"SELECT oid, rolname, rolsuper, rolinherit, "
682+
"rolcreaterole, rolcreatedb, "
683+
"rolcanlogin, rolconnlimit, rolpassword, "
684+
"rolvaliduntil, rolreplication, rolbypassrls, "
685+
"pg_catalog.shobj_description(oid, 'pg_authid') as rolcomment, "
686+
"rolname = current_user AS is_current_user "
687+
"FROM pg_authid "
688+
"ORDER BY 2");
679689
elseif (server_version >=90100)
680690
printfPQExpBuffer(buf,
681691
"SELECT oid, rolname, rolsuper, rolinherit, "

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp