Re: pg_dump with postgis extension dumps rules separately

From: Joe Conway <mail(at)joeconway(dot)com>
To: Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>
Cc: Andres Freund <andres(at)2ndquadrant(dot)com>, postgres hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_dump with postgis extension dumps rules separately
Date: 2013-05-30 14:05:24
Message-ID: 51A75CA4.7070200@joeconway.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 05/30/2013 02:02 AM, Dimitri Fontaine wrote:
> Joe Conway <mail(at)joeconway(dot)com> writes:
>> Here's a cleaned up version, which also includes documentation.
>> I'll commit back to 9.1 in a day or two unless there are any
>> objections.
>
> Looks good to me.
>
> Were you able to test it against an extension containing both rules
> and views, to check that pg_dump has no problem with the new set
> of dependencies?

PostGIS has both:

test=# \dv
List of relations
Schema | Name | Type | Owner
- --------+-------------------+------+----------
public | geography_columns | view | postgres
public | geometry_columns | view | postgres
public | raster_columns | view | postgres
public | raster_overviews | view | postgres
(4 rows)

select tablename, rulename from pg_rules ;
tablename | rulename
- ------------------+-------------------------
pg_settings | pg_settings_n
pg_settings | pg_settings_u
geometry_columns | geometry_columns_delete
geometry_columns | geometry_columns_update
geometry_columns | geometry_columns_insert
(5 rows)

8<----------------
# pg_dump test > /tmp/test-01.dmp
# dropdb test
# createdb test
# psql test < /tmp/test-01.dmp
SET
SET
SET
SET
SET
SET
CREATE EXTENSION
COMMENT
CREATE EXTENSION
COMMENT
SET
REVOKE
REVOKE
GRANT
GRANT
# pg_dump test > /tmp/test-02.dmp
# diff /tmp/test-01.dmp /tmp/test-02.dmp
...<no differences>...
8<----------------

Joe

- --
Joe Conway
credativ LLC: http://www.credativ.us
Linux, PostgreSQL, and general Open Source
Training, Service, Consulting, & 24x7 Support
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBAgAGBQJRp1ykAAoJEDfy90M199hlLQcP/1OkpFeb99EO9xca0RD+WIHS
FrqhBEJDHA4ujODvitZRMTFjpS1WH4Difm7P05Lvbr1xEUmwuSD6oBw/VQ1p6cxs
RyIvUM1uLVhR/nwjMeymner9kOINPu4rBVKf+7EgPJQcFvZuUSzafNGH1l70p6wk
dXMA2ggjjFdvF6voVxaKkHFbs+uttURNDZ2l0f6eb4QJRZta+NuFCOtIkPTqBESx
oABWuoAutAEX0Z7b0iEyNjjDLduPzjMIqQm8Y6NfsGmkEYd2jrpYVl04T8hcbqf0
vFJ2NvblvuaHoRIhq/ZYbFt9dQKIdoUtNuzR8MOK474mD/VrX6v/xquGh1rcmL4x
1k94Lis3Cf/QEBUEqwKNribkOLemaxEEDVnVTCWSC59FoDbaAZuiwtYspHYwAQED
D3nZ9jknEr+Bziqw6y8KP3wQGAbyssIKdtXFlw2u1BFeFjuWK5pL8vR3vi08j/Ij
diycCOBLotJGlkaHEt7vCNMTbHlIru4d4yblh0hbB6wL6JvI2HbGlK5chPPqIu+O
zHpPGUuTy7lgi+0809k5ceoqYUDJJTo0yu/3BuvLeaZwJqfS9QBIjCdryb/0MCVn
QJ6u3r54aSz4FQHP8iDoDnfbZIAdpCtjlqiTxLARxxYZqWt9nHoW0bC9fZpTkBfT
YxJX5C74NCVHE2Qdqnqx
=fbuL
-----END PGP SIGNATURE-----

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2013-05-30 14:47:42 Re: Behavior of a pg_trgm index for 2 (or < 3) character LIKE queries
Previous Message Robert Haas 2013-05-30 13:51:28 Re: fallocate / posix_fallocate for new WAL file creation (etc...)