Andreas wrote:
> Hi,
> for some cleaning up I'd like to drop a certain role.
> Now DROP ROLE yields an error and complains about 271 objects being
> owned by this role.
>
> Is there an easy way to switch ownership of those objects to another role?
Yes, see REASSIGN OWNED (gives ownership to something else) and DROP
OWNED (drops grants and removes objects owned). Normally you run both
in that order.
--
Alvaro Herrera http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.