]> granicus.if.org Git - postgresql/commit
Fix dumping of security_barrier views with circular dependencies.
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 21 Aug 2012 19:18:36 +0000 (15:18 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 21 Aug 2012 19:18:36 +0000 (15:18 -0400)
commit0f524ea0cf388a149f362e48a33c01662eeddc04
tree306092fe85e6cffbc515b26c688654487a531c46
parent4b373e42d1efd24f871193ce8178c41f199c5df3
Fix dumping of security_barrier views with circular dependencies.

If a view has circular dependencies, pg_dump splits it into a CREATE TABLE
and a CREATE RULE command to break the dependency loop.  However, if the
view has reloptions, those options cannot be applied in the CREATE TABLE
command, because views and tables have different allowed reloptions so
CREATE TABLE would reject them.  Instead apply the reloptions after the
CREATE RULE, using ALTER VIEW SET.
src/bin/pg_dump/pg_dump.c
src/bin/pg_dump/pg_dump.h
src/bin/pg_dump/pg_dump_sort.c