Re: How to dump JUST procedures/funnctions?

Поиск
Список
Период
Сортировка
От Tony Wasson
Тема Re: How to dump JUST procedures/funnctions?
Дата
Msg-id 6d8daee31003221657h53f486d7r164b27587415e8c6@mail.gmail.com
обсуждение исходный текст
Ответ на Re: How to dump JUST procedures/funnctions?  ("Carlo Stonebanks" <stonec.register@sympatico.ca>)
Ответы Re: How to dump JUST procedures/funnctions?  ("Carlo Stonebanks" <stonec.register@sympatico.ca>)
Список pgsql-general
On Sat, Mar 20, 2010 at 11:09 PM, Carlo Stonebanks <stonec.register@sympatico.ca> wrote:
Is pg_get_functiondef an 8.4 appears to be an 8.4 function?

I don't see it in the 8.3 documentation and the servers in question are all 8.3.

Any alternatives for 8.3? pg_proc has the code body, but not the function declaration, etc.


I've attached a simple perl script to dump all functions per schema from a database. I won't claim this is perfect, but it does the trick for me.

Works with 8.3. If you have 2 functions called public.foo, it will put them in public/foo.sql with CREATE OR REPLACE FUNCTION formatting around it.

Hope this is useful to others.
Tony Wasson


Вложения

В списке pgsql-general по дате отправления:

Предыдущее
От: Igor
Дата:
Сообщение: server-side extension in c++
Следующее
От: Adrian Klaver
Дата:
Сообщение: Re: Create a function that updates the record with and timestamps