How to change ownership of all objects in a database
If you need to change ownership of all database objects in the current database, use this anonymous DO block (or copy-paste from here):
If you need to change ownership of all database objects in the current database, use this anonymous DO block (or copy-paste from here):