Steve Crawford wrote:
How can I dump a function definition with pg_dump?
Background: We often need to create objects that are all relevant to
only a specific project. Sometimes it is a single table. Other times
there are many tables, indexes, views, rules, triggers and functions.
All the objects share a unique substring that identifies the project so
automatically creating the list is easy.
When I use pg_dump to dump a table I will by default also get the
associated indexes, rules and triggers. Views can be dumped just like
tables. So all I need to do to archive the whole mess is to automate the
dump of the functions.
Ideas?
Cheers,
Steve
This thread has a few options available
http://archives.postgresql.org/pgsql-general/2005-10/msg01589.php