What are the different privileges required for using views?


Following privileges are required for a different kind of CREATE, REPLACE, DROP, ACCESS, UPDATE etc. of usage of views −

  •  CREATE VIEW Privilege − CREATE VIEW privilege is required to create a view. Along with this we must have sufficient privileges, like SELECT, INSERT or UPDATE, for accessing the tables to which the view definition refers.
  •  DROP VIEW Privilege − We require DROP VIEW privileges for using OR REPLACE clause, DROP VIEW statement and also for using ALTER VIEW statement.
  •  SELECT Privilege − We must have SELECT privileges for selecting from a view.
  •  INSERT, DELETE or UPDATE Privileges − Actually for an updateable view to use INSERT, DELETE or UPDATE statements we must have INSERT, DELETE or UPDATE privileges.
  •  SHOW VIEW Privilege − If the view definition refers to tables for which we have no privileges then we must have SHOW VIEW privileges along with SELECT privileges.

Lakshmi Srinivas
Lakshmi Srinivas

Programmer / Analyst / Technician

Updated on: 22-Jun-2020

93 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements