17.10 - CREATE FUNCTION MAPPING and REPLACE FUNCTION MAPPING Syntax Elements - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - SQL Data Definition Language Syntax and Examples

Product
Advanced SQL Engine
Teradata Database
Release Number
17.10
Release Date
July 2021
Content Type
Programming Reference
Publication ID
B035-1144-171K
Language
English (United States)
database_name_1
Name of database to contain the function mapping, if other than the current database.
user_name_1
Name of user to contain the function mapping, if other than the current user.
function_mapping_name
Name of function mapping. For information on naming objects, see Teradata Vantage™ - SQL Fundamentals, B035-1141.
database_name_2
Name of the database containing the function, if other than the current database for the session.
user_name_2
Name of the user containing the function, if other than the current user for the session.
schema_name
Name of schema associated with function.
function_name
Name of function or table operator to map.
You must make sure that the function is present in the location you specify.
For functions or table operators stored within the database, if you do not specify a database or user, the location defaults to the following, in order of precedence:
  • Current default database or user for the session
  • SYSLIB
  • TD_SYSFNLIB
See Example: Function Mapping Definition for a Function Within the Database.
SERVER
Name of external server where the function or table operator is located.
For a function or table operator within the database, you do not specify the SERVER clause.
database_name_3
Name of database to contain the function, if other than the current database.
user_name_3
Name of user to contain the function, if other than the current user.
server_name
Name of server containing the function.
EXTERNAL SECURITY
Specifies an authorization for accessing remote storage. See CREATE AUTHORIZATION and REPLACE AUTHORIZATION.
DEFINER
Specify DEFINER to share an authorization object with multiple users of the database in which it resides. You can create the authorization in any database.
INVOKER
Specify INVOKER to allow exclusive access by a user. You must create the authorization in the database of the current user.
TRUSTED
Required keyword.
authorization_name
Name of the authorization object.
json_document
JSON format document containing input to function in the form of parameters and values.
STOREDAS
Use only when creating a mapping for the WRITE_NOS table operator.
Specifies the formatting style of the external data:
Option Description
'PARQUET' External data is formatted as Parquet.

For Parquet data, you must specify STOREDAS ('PARQUET').

'TEXTFILE' (default) External data uses a text-based format, such as CSV or JSON.