Name

REVOKE (Object Privileges)

Synopsis

REVOKE
{object_priv[,object_priv
...] | ALL [PRIVILEGES] }
ON
[schema.]object_name
TO {username |
role | PUBLIC}

Revokes privileges on a database object (object_name) for one or more users (username) or roles (role).

Keywords

object_priv

Specifies the name of the object privilege to be revoked. Valid privileges are: ALTER, DELETE, EXECUTE, INDEX, INSERT, REFERENCES, SELECT, and UPDATE. ALL PRIVILEGES revokes all privileges granted for this object.

PUBLIC

Specifies that the object privilege will be revoked for all current and future users.

Notes

The object must be in your schema or you must have been granted the object privileges via the WITH GRANT OPTION. If you revoke a privilege from a user who has granted that privilege to others, the revoke is cascaded, so the privilege is revoked from the other user.

Example

The following example revokes INSERT and UPDATE privileges from scott’s emp table:

REVOKE insert,update ON scott.emp
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset