Appearance
HAS_CLUSTER_PRIVILEGE
Return true if the user has the specified privilege on the specified cluster.
HAS_EXTERNAL_STORAGE_PRIVILEGE([role,] object, privilege)- role
If the
role(or user) name is omitted, the function returns results for the current user.- object
Name of an existing cluster.
- privilege
Specify one of the following privileges:
USAGEUSAGE WITH GRANT OPTIONALTER CLUSTERALTER CLUSTER WITH GRANT OPTIONDROP CLUSTERDROP CLUSTER WITH GRANT OPTION
For example:
yellowbrick=# select has_cluster_privilege('uat-rc5-cluster-01','usage');
has_cluster_privilege
-----------------------
t
(1 row)
yellowbrick=# select has_cluster_privilege('hkane@thfc.com','uat-rc5-cluster-01', 'usage');
has_cluster_privilege
-----------------------
f
(1 row)Parent topic:System Functions