Create a New UDT - Teradata Administrator

Teradata Administrator User Guide

Product
Teradata Administrator
Release Number
15.10
Language
English (United States)
Last Update
2018-10-07
dita:id
B035-2502
Product Category
Teradata Tools and Utilities

Creating a UDT normally requires execution of many statements. The CREATE FUNCTION and CREATE METHOD statements can only be done using Teradata Administrator if the source code or object is already on the server. If the source is on the client, use BTEQ to create these objects. The template provided when creating the UDT assumes server side source code files are being used; therefore, edit these if your site uses object files.

Use the following procedure to create a new UDT.

1 From the main window, click Tools > Administer UDTs or Tools > Create > Type.

2 Define the attributes and options as indicated in Table 21.

3 Enter a new Type Name.

If an existing UDT is displayed in the Type Name box, simply type over the name to create a new UDT.

4 Click Distinct, or Structured, or Array.

When the Array option is selected, the Bounds text box and Default Null check box appear. In this case, you must enter the upper and lower bounds values. For information about these features, refer to “UDT Attributes and Options” on page 75

5 [Optional] In the Comment box, type a comment that might describe the data type.

6 Click Create when finished.

The DDL is checked to ensure no angle brackets remain. If the UDT is created successfully, it is added to the cache. If the remaining statements complete successfully, the status bar indicates the UDT was created. To correct errors, see “Correct Errors” on page 73.

Correct Errors

If all statements do not complete successfully, an error message is inserted after the statement(s) that failed, and processing stops. The word Completed follows the statement(s) that complete successfully.

Use the following procedure to correct errors.

  • Correct the error and click Continue.
  • Either remove the statements that complete, or leave them as they are, but do not remove the ***completed messages while leaving the statements themselves.