不同于 GRANT,REVOKE 语句没有语法来对表中的列的子集指定权限。要从用户取消对列的 Select、Update 或 References 权限,您必须对该表的所有列取消该权限。要提供对您先前已在其上授予了权限的一些列的访问,请发出新的 GRANT 语句来恢复对特定列的适当的权限。
REVOKE SELECT ON customer FROM PUBLIC; GRANT SELECT (fname, lname, company, city) ON customer TO PUBLIC;
GRANT REFERENCES (fname, lname, company, city) ON customer TO mary; REVOKE REFERENCES ON customer FROM mary; GRANT REFERENCES (company, city) ON customer TO mary;