Search Postgresql Archives

Re: table dump function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 03/07/2013 07:58 AM, Little, Douglas wrote:
I need a pl/pgsql function that will dump a table ddl  so I can export
the definition to a file  before I drop the object.

the psql \d command won’t work, since it doesn’t dump the table ddl, it
just lists the table’s attributes and indexes.

I’ve got the function mostly working,  but need help translating the ACL
list into the grant commands.

Are there any standard PG functions that would be useful  for creating
the grants?


pg_dump -U some_user -t some_table -s -f some_table.sql some_database

http://www.postgresql.org/docs/9.2/interactive/app-pgdump.html

Thanks in advance.

*Doug Little*



--
Adrian Klaver
adrian.klaver@xxxxxxxxx


--
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux