I'm working on a tool to simplify updating the source code of database
functions.
To do a "revert" my plan is to store the values of pg_proc.* before
updating, and then to restore pg_proc for the given oid if a revert is
necessary.
This raises the question,
Is it "safe" to do,
UPDATE pg_proc SET <column> = <new source code> WHERE oid = <function's
oid>;
instead of using the "CREATE OR REPLACE FUNCTION" command?
(Using pg_dump -s + pg_restore isn't feasible since it operates on the
entire schema, and not just a subset of functions, important in my case.)
Thanks for any advise.
--
Best regards,
Joel Jacobson
Glue Finance