The Vertica Forum recently got a makeover! Let us know what you think by filling out this short, anonymous survey.

Change the Owner of a Schema

Jim Knicely authored this tip.

As of Vertica 9.1.1, you can now transfer the ownership of a schema to another user!

Example:

dbadmin=> SELECT schema_name, schema_owner FROM schemata WHERE schema_name = 'my_etl_schema';
  schema_name  | schema_owner
---------------+--------------
 my_etl_schema | dbadmin
(1 row)

dbadmin=> CREATE USER etl_user;
CREATE USER

dbadmin=> ALTER SCHEMA my_etl_schema OWNER TO etl_user;
ALTER SCHEMA

dbadmin=> SELECT schema_name, schema_owner FROM schemata WHERE schema_name = 'my_etl_schema';
  schema_name  | schema_owner
---------------+--------------
 my_etl_schema | etl_user
(1 row)

Have fun!

Sign In or Register to comment.

Can't find what you're looking for? Search the Vertica Documentation, Knowledge Base, or Blog for more information.