why do i get ORA-01031: insufficient privileges ?
SQL> grant create view to rojib;
Error :
grant create view to rojib
*
ERROR at line 1:
ORA-01031: insufficient privileges
In order to grant the CREATE VIEW
privilege, your user needs the CREATE VIEW
privilege WITH ADMIN OPTION
, or the GRANT ANY PRIVILEGE
system privilege. Otherwise you have insufficient privileges.
http://docs.oracle.com/cd/E11882_01/server.112/e41084/statements_9013.htm#i2094944
To grant a system privilege, one of the following conditions must be met:
You must have been granted the GRANT ANY PRIVILEGE system privilege. In this case, if you grant the system privilege to a role, then a user to whom the role has been granted does not have the privilege unless the role is enabled in user's session.
You must have been granted the system privilege with the ADMIN OPTION. In this case, if you grant the system privilege to a role, then a user to whom the role has been granted has the privilege regardless whether the role is enabled in the user's session.