Privileges

Privileges granted to a user or role determine which operations the user or role can perform on certain objects. Privileges can be used to implement fine-grained access control to safeguard data security.

This topic describes privileges provided by CelerData Cloud Serverless on different objects and their meanings. Privileges are granted and revoked by using GRANT and REVOKE. The privileges that can be granted on an object are specific to the object type. For example, table privileges are different from database privileges.

Privilege list

This section describes privileges that are available on different objects.

ACCOUNT

PrivilegeDescription
GRANTCreates a user or role, alters a user or role, or grants privileges to a user or role. This privilege cannot be directly granted to users or roles. The user_admin role has this privilege.
CREATE EXTERNAL CATALOGCreates an External Catalog.
REPOSITORYCreates, deletes, or views repositories.
OPERATEManages replicas, configuration items, variables, and transactions.
CREATE GLOBAL FUNCTIONCreates a global UDF.

USER

PrivilegeDescription
IMPERSONATEAllows user A to perform operations as user B.

GLOBAL FUNCTION (Global UDFs)

PrivilegeDescription
USAGEUses a function in a query.
DROPDeletes a function.
ALLHas all the above privileges on a function.

CATALOG

ObjectPrivilegeDescription
CATALOG (internal catalog)USAGEUses the internal catalog (default_catalog).
CATALOG (internal catalog)CREATE DATABASECreates databases in the internal catalog.
CATALOG (internal catalog)ALLHas all the above privileges on the internal catalog.
CATALOG (external catalog)USAGEUses an external catalog to view tables in it.
CATALOG (external catalog)DROPDeletes an external catalog.
CATALOG (external catalog)ALLHas all the above privileges on the external catalog.

NOTE

The internal catalog in your CelerData cloud account can not be deleted.

DATABASE

PrivilegeDescription
ALTERSets properties for a database, rename a database, or sets quotas for a database.
DROPDeletes a database.
CREATE TABLECreates tables in a database.
CREATE VIEWCreates a view.
CREATE FUNCTIONCreates a function.
CREATE MATERIALIZED VIEWCreates a materialized view.
ALLHas all the above privileges on a database.

TABLE

PrivilegeDescription
ALTERModifies a table or refreshes metadata in an external table.
DROPDrops a table.
SELECTQueries data in a table.
INSERTInserts data into a table.
UPDATEUpdates data in a table.
EXPORTExports data from a table.
DELETEDeletes data from a table based on the specified condition or deletes all the data from a table.
ALLHas all the above privileges on a table.

VIEW

PrivilegeDescription
SELECTQueries data in a view.
ALTERModifies the definition of a view.
DROPDeletes a logical view.
ALLHas all the above privileges on a view.

MATERIALIZED VIEW

PrivilegeDescription
SELECTQueries a materialized view to accelerate queries.
ALTERChanges a materialized view.
REFRESHRefreshes a materialized view.
DROPDeletes a materialized view.
ALLHas all the above privileges on a materialized view.

FUNCTION (Database-level UDFs)

USAGEUses a function.
DROPDeletes a function.
ALLHas all the above privileges on a function.