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

Commit64d60c8

Browse files
committed
Correct pg_dump WHERE clause for functions/aggregates
The query to grab the function/aggregate information is now joiningto pg_init_privs, so we can simplify (and correct) the WHERE clauseused to determine if a given function's ACL has changed from theinitial ACL on the function.Bug found by Noah, patch by me.
1 parente324f8a commit64d60c8

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

‎src/bin/pg_dump/pg_dump.c

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4673,11 +4673,7 @@ getAggregates(Archive *fout, int *numAggs)
46734673
"p.pronamespace != "
46744674
"(SELECT oid FROM pg_namespace "
46754675
"WHERE nspname = 'pg_catalog') OR "
4676-
"EXISTS (SELECT * FROM pg_init_privs pip "
4677-
"WHERE p.oid = pip.objoid AND pip.classoid = "
4678-
"(SELECT oid FROM pg_class "
4679-
"WHERE relname = 'pg_proc') "
4680-
"AND p.proacl IS DISTINCT FROM pip.initprivs)",
4676+
"p.proacl IS DISTINCT FROM pip.initprivs",
46814677
username_subquery,
46824678
acl_subquery->data,
46834679
racl_subquery->data,
@@ -4923,11 +4919,7 @@ getFuncs(Archive *fout, int *numFuncs)
49234919
"pronamespace != "
49244920
"(SELECT oid FROM pg_namespace "
49254921
"WHERE nspname = 'pg_catalog') OR "
4926-
"EXISTS (SELECT * FROM pg_init_privs pip "
4927-
"WHERE p.oid = pip.objoid AND pip.classoid = "
4928-
"(SELECT oid FROM pg_class "
4929-
"WHERE relname = 'pg_proc') "
4930-
"AND p.proacl IS DISTINCT FROM pip.initprivs)",
4922+
"p.proacl IS DISTINCT FROM pip.initprivs",
49314923
acl_subquery->data,
49324924
racl_subquery->data,
49334925
initacl_subquery->data,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp