Re: [GENERAL] ALTER FUNCTION
От | Adriaan Joubert |
---|---|
Тема | Re: [GENERAL] ALTER FUNCTION |
Дата | |
Msg-id | 38466F38.E10C3889@albourne.com обсуждение исходный текст |
Ответ на | ALTER FUNCTION (Sascha Ziemann <szi@khs-ag.de>) |
Список | pgsql-general |
Just drop the function, drop all triggers that use the function, re-create the function and recreate all triggers. If the function is called by other PL functions, you need to drop and re-install those as well. If you keep them all in a big file, every one preceded by drop, you can just reload the file (with \i into psql) whenever you have changed something. No need to dump any data. Adriaan > > UPDATE pg_proc SET prosrc='SQL statement' WHERE proname LIKE > 'functionname'; > > seems to work for SQL queries at least. I doubt it's recommended, > though! > > > > > are there plans for an ALTER FUNCTION statement for Postgresql? I > > think functions are completely unuseable, when it is not possible to > > change the definition of a function. A bugfix in a function > requires > > the export of all data, a redefinition of the function and a > complete > > reimport. Or is there a simpler way?
В списке pgsql-general по дате отправления: