15.10 - FOR UDT.name - Teradata Database

Teradata Database SQL Data Definition Language Syntax and Examples

prodname
Teradata Database
vrm_release
15.10
created_date
December 2015
category
Programming Reference
featnum
B035-1144-151K
EXECUTE PROTECTED
Change the execution mode for the specified method from unprotected mode to protected mode. See the ALTER PROCEDURE (External Form) topic “When to Specify Unprotected Mode” in SQL Data Definition Language - Detailed Topics, B035-1184 for details.
NOT
Change the execution mode for the specified method from protected mode to unprotected mode. See the ALTER PROCEDURE (External Form) topic “When to Specify Unprotected Mode” in SQL Data Definition Language - Detailed Topics, B035-1184 for details.
COMPILE
Recompile the code source for the specified method, generate the object code, recreate the .so or .dll, and distribute it to all nodes of the system.
The existing method object is replaced by the recompiled version.
ONLY
Recompile the method only. When you specify this option, Teradata Database does not distribute a new dynamic linked library to database nodes.
When you load a method onto another platform of a different type, the system marks it as not valid, and it must be recompiled. If there are many methods in one database, it saves time to specify the ONLY option for all recompilations to avoid having to generate and distribute a new library, until the last one is compiled in that database leaving off the ONLY option.

Example: Changing the Protection Mode

The following ALTER METHOD request changes the protection mode for the method named polygon_mbr() from protected to not protected:

    ALTER METHOD polygon_mbr() FOR SYSUDTLIB.polygon
    EXECUTE NOT PROTECTED;

Example: Recompiling a Method Object

The following ALTER METHOD request recompiles the specific method object named SYSUDTLIB.polygon_mbr:

    ALTER SPECIFIC METHOD SYSUDTLIB.polygon_mbr COMPILE;