| От | Tom Lane |
|---|---|
| Тема | Re: How do you backup functions only? |
| Дата | |
| Msg-id | 19489.1141055099@sss.pgh.pa.us обсуждение |
| Ответ на | How do you backup functions only? ("Andrew Walmsley" <andrew.walmsley@ttsltd.com>) |
| Список | pgsql-novice |
"Andrew Walmsley" <andrew.walmsley@ttsltd.com> writes:
> This creates a non-restorable snapshot of the functions. Is there a way
> to output the functions (only) so that they can be restored in one easy
> operation if there is an error in the new code? An option to pg_dump
> that I have missed perhaps?
No, but I'd still recommend using "pg_dump -s -Fc" to backup the
complete database schema including the functions. A semi-automated
way to extract just the functions from such a dump is to use
pg_restore -l, grep the output for FUNCTION, then feed the resulting
list into pg_restore -L.
regards, tom lane
В списке pgsql-novice по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера