Postgres: To find the owner of a function and to change owner

 SELECT

proname AS function_name,
proowner::regrole AS owner_name
FROM
pg_proc
WHERE
pronamespace::regnamespace::text = 'cpnadmin';



ALTER FUNCTION cpnadmin.assign_coupon_batch OWNER TO cpnadmin;

Comments

Popular posts from this blog

Postgres: To list table owners

PeopleSoft: Clean Up PUM

Postgres: To check the locale / Character set settings