The privileges to create, drop, execute, or alter a procedure can be granted using the GRANT statement and revoked using the REVOKE statement.
This privilege … | Can be granted to this level of database object … |
---|---|
CREATE PROCEDURE |
|
|
|
- DROP PROCEDURE is granted automatically to all users and databases when a new user or database is created.
- EXECUTE PROCEDURE is granted automatically only to the creator of a stored procedure when the object is created.
Teradata Database does not grant this privilege automatically to the owner of the stored procedure when the owner and creator are not the same.
The immediate owner of a stored procedure is the user or database space where the stored procedure is created. The creator is the user who creates the stored procedure in any database.
Related Topics
For more information about:
- Stored procedures, see Stored Procedure Overview.
- External stored procedures, see Teradata Vantage™ - SQL Data Definition Language Detailed Topics , B035-1184 and Teradata Vantage™ - SQL External Routine Programming , B035-1147 .
- SQL forms of the GRANT and REVOKE statements and the ALTER PROCEDURE, CREATE PROCEDURE, DROP PROCEDURE, and EXECUTE PROCEDURE privileges, see Teradata Vantage™ - SQL Data Control Language, B035-1149.