Documentation IndexFetch the complete documentation index at: /llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
The ALTER VIEW command modifies the metadata of a view. To use this command, you must own the view.
ALTER VIEW
ALTER VIEW view_name alter_option;
alter_option
OWNER TO
ALTER VIEW view_name OWNER TO new_user;
-- Change the owner of the view named "view1" to user "user1" ALTER VIEW view1 OWNER TO user1;
SET SCHEMA
ALTER VIEW view_name SET SCHEMA schema_name;
-- Move the view named "test_view" to the schema named "test_schema" ALTER VIEW test_view SET SCHEMA test_schema;
RENAME TO
ALTER VIEW view_name RENAME TO new_name;
-- Change the name of the view named "view1" to "view2" ALTER VIEW view1 RENAME TO view2;
SWAP WITH
ALTER VIEW name SWAP WITH target_name;
-- Swap the names of the user_profiles view and the guest_profiles view. ALTER VIEW user_profiles SWAP WITH guest_profiles;
Was this page helpful?