SQL/MX 2.x Reference Manual (H06.04+)

SQL/MX Statements
HP NonStop SQL/MX Reference Manual540440-003
2-168
Considerations for REVOKE
clause is the same as if the authid-grantor were to issue the REVOKE directly
(without using the BY clause).
authid-grantor must be a valid authorization ID and cannot be SYSTEM.
Considerations for REVOKE
Authorization and Availability Requirements
You can revoke only those privileges that you have previously granted to the user. If
one or more of the privileges does not exist, the system returns a warning.
If the super ID has issued a REVOKE using the BY authid-grantor clause, the
authid-grantor must have previously granted the specified privileges to the
specified authorization IDs.
You cannot revoke privileges from a user of the system if you have granted privileges
to PUBLIC.
Examples of REVOKE
This example revokes one user’s SELECT privileges on a table:
REVOKE SELECT ON TABLE persnl.employee
FROM "sql.user1" RESTRICT;
This example revokes the privileges of granting SELECT and DELETE privileges
on a table from two users:
REVOKE GRANT OPTION FOR SELECT, DELETE
ON TABLE sales.odetail FROM "sql.user1", "sql.user2";
This example revokes UPDATE privileges on two columns of a table:
REVOKE UPDATE (start_date, ship_timestamp)
ON TABLE persnl.project FROM PUBLIC RESTRICT;
In this example the super ID revokes SELECT and DELETE privileges on a table
on behalf of sql.user1:
REVOKE SELECT, DELETE ON TABLE sales.odetail
FROM "sql.user3" BY "sql.user1";