How to Specify Files for User-Defined Functions | Basic Teradata Query - 17.00 - Specifying Files for User-Defined Functions - Basic Teradata Query

Basic Teradata® Query Reference

Basic Teradata Query
June 2020
Programming Reference

When a programming task cannot be accomplished with SQL’s built-in functions, optional solutions include writing a user-defined function in standard C, C++, or Java programming languages to extend a set of available functions.

The C, C++, or Java files can reside on the server or the client. The server calls for the transfer of client-resident files as needed for input requirements for the CREATE or REPLACEFUNCTION request. Source files must be encoded as ASCII (workstation) or EBCDIC (mainframe), regardless of the current session character set. Note, the same transfer protocol is employed when using client-resident files to create user-defined methods (UDMs) and external stored procedures (XSPs).

Starting with Teradata Database 13.10 and BTEQ 13.10, the encoding expected for file name values is based on session character set rather than solely on the platform-appropriate single-byte character sets of ASCII or EBCDIC. This means that, for Unicode sessions only, the transfer protocol is not forward- or backward-compatible when a 13.10 version of either Teradata Database or BTEQ is used with an older version of the other.