Re: pg_get_procdef ?

From: hubert depesz lubaczewski <depesz(at)depesz(dot)com>
To: Marc Mamin <M(dot)Mamin(at)intershop(dot)de>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: pg_get_procdef ?
Date: 2010-10-27 09:59:44
Message-ID: 20101027095943.GA19416@depesz.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Oct 27, 2010 at 11:21:43AM +0200, Marc Mamin wrote:
> Hello,
>
> I want to export a list of procedure definitions, which seems to be a
> hard nut to crack :-(
> A solution could be to use a combination of pg_dump and pg_restore, but
> this also requires some time investment.
> It would be fine, if pg_dump could be more selective about the object to
> select...
>
> Does anyone have a handmade solution for a pg_get_procdef function.
>
> I'm still on Postgres 8.3 ...

pg_dump -Fc -s + pg_restore -l | grep + pg_restore -L will be fast.

if that's not good enough for you, do:
psql -E
\df+ function

and check the queries. getting function definition from there should be
simple.

Best regards,

depesz

--
Linkedin: http://www.linkedin.com/in/depesz / blog: http://www.depesz.com/
jid/gtalk: depesz(at)depesz(dot)com / aim:depeszhdl / skype:depesz_hdl / gg:6749007

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dmitriy Igrishin 2010-10-27 10:14:45 Re: Advice needed on application/database authentication/authorization/auditing model
Previous Message Marc Mamin 2010-10-27 09:21:43 pg_get_procdef ?