Content-Length: 267700 | pFad | http://github.com/postgrespro/postgres/commit/e0d4a290f4a24b0a0a46af4d0f8551f8ee5e5513

CE Fix pg_dump output of policies. · postgrespro/postgres@e0d4a29 · GitHub
Skip to content

Commit e0d4a29

Browse files
committed
Fix pg_dump output of policies.
pg_dump neglected to wrap parenthesis around USING and WITH CHECK expressions -- fixed. Reported by Noah Misch.
1 parent 3d5cb31 commit e0d4a29

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/bin/pg_dump/pg_dump.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3012,10 +3012,10 @@ dumpPolicy(Archive *fout, DumpOptions *dopt, PolicyInfo *polinfo)
30123012
appendPQExpBuffer(query, " TO %s", polinfo->polroles);
30133013

30143014
if (polinfo->polqual != NULL)
3015-
appendPQExpBuffer(query, " USING %s", polinfo->polqual);
3015+
appendPQExpBuffer(query, " USING (%s)", polinfo->polqual);
30163016

30173017
if (polinfo->polwithcheck != NULL)
3018-
appendPQExpBuffer(query, " WITH CHECK %s", polinfo->polwithcheck);
3018+
appendPQExpBuffer(query, " WITH CHECK (%s)", polinfo->polwithcheck);
30193019

30203020
appendPQExpBuffer(query, ";\n");
30213021

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/postgrespro/postgres/commit/e0d4a290f4a24b0a0a46af4d0f8551f8ee5e5513

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy