17.05 - UDTMETHOD Privilege - Teradata Database

Teradata Vantageā„¢ - SQL Data Control Language

prodname
Advanced SQL Engine
Teradata Database
vrm_release
17.00
17.05
created_date
June 2020
category
Programming Reference
featnum
B035-1149-170K

The UDTMETHOD privilege allows a user to use any UDT and its methods without any restrictions. Its functionally includes both of the following privileges:

  • UDTUSAGE on all UDTs in the SYSUDTLIB database.
  • UDTTYPE on the SYSUDTLIB database.

A user with the UDTMETHOD privilege can perform these statements and operations:

  • CREATE TYPE with or without specifying method signatures.
  • DROP TYPE.
  • ALTER TYPE with or without adding or dropping method signatures.
  • CREATE ORDERING and DROP ORDERING.
  • CREATE CAST and DROP CAST.
  • CREATE TRANSFORM and DROP TRANSFORM.
  • CREATE TABLE with UDT columns.
  • Reference any UDT in an SQL statement, UDF, or procedure.
  • Execute all methods.
  • CREATE METHOD and ALTER METHOD and REPLACE METHOD.

The specified database_name in the ON clause must be SYSUDTLIB.

UDTMETHOD is not an automatically granted privilege. A user must be granted it explicitly, or acquire it through ALL PRIVILEGES or through a role. Users who are granted UDTMETHOD WITH GRANT OPTION can then grant others the UDTUSAGE, UDTTYPE, or UDTMETHOD privilege, optionally with the WITH GRANT option.

UDTMETHOD is represented by the code UM in the AccessRight column of the DBC.AccessRights table.

The following GRANT requests grant the following respective privileges:

  • UDTMETHOD on SYSUDTLIB to the user named user_DBA with grant option.
  • UDTMETHOD on SYSUDTLIB to the role named developer_role.
    GRANT UDTMETHOD
         ON SYSUDTLIB
         TO user_DBA WITH GRANT OPTION;
         
         GRANT UDTMETHOD
         ON SYSUDTLIB
         TO developer_role;