FUNCTIONS view

This Information Schema view displays a row for each user-defined function (UDF), external function, or data metric function defined in the specified (or current) database.

For more information about external functions, see Writing external functions. For more information about UDFs, see User-defined functions overview.

Columns

Column NameData TypeDescription
FUNCTION_CATALOGVARCHARDatabase to which the function belongs.
FUNCTION_SCHEMAVARCHARSchema to which the function belongs.
FUNCTION_NAMEVARCHARFunction name.
FUNCTION_OWNERVARCHARName of the role that owns the function.
ARGUMENT_SIGNATUREVARCHARType signature of the function’s arguments.
DATA_TYPEVARCHARData type of the function’s return value.
CHARACTER_MAXIMUM_LENGTHNUMBER(9,0)Maximum length in characters of a string return value.
CHARACTER_OCTET_LENGTHNUMBER(9,0)Maximum length in bytes of a string return value.
NUMERIC_PRECISIONNUMBER(9,0)Numeric precision of numeric return value.
NUMERIC_PRECISION_RADIXNUMBER(9,0)Radix of precision of numeric return value.
NUMERIC_SCALENUMBER(9,0)Scale of numeric return value.
FUNCTION_LANGUAGEVARCHARLanguage of the function’s handler.
FUNCTION_DEFINITIONVARCHARDefinition of the function’s handler.
VOLATILITYVARCHARVOLATILE if the function is volatile; IMMUTABLE if it is immutable.
IS_NULL_CALLVARCHAR(3)YES if the function is called on null input; otherwise, NO.
IS_SECUREVARCHAR(3)YES if the function is secure; otherwise, NO.
CREATEDTIMESTAMP_LTZCreation time of the function.
LAST_ALTEREDTIMESTAMP_LTZDate and time the object was last altered by a DML, DDL, or background metadata operation. See Usage Notes.
COMMENTVARCHARComment for the function.
IS_EXTERNAL [1]VARCHAR(3)YES if the function is an external function; otherwise, NO.
API_INTEGRATION [1]VARCHARName of the API integration object to authenticate the call to the proxy service an external function makes.
CONTEXT_HEADERS [1]VARCHARContext header information for the external function.
MAX_BATCH_ROWS [1]NUMBER(9,0)Maximum number of rows in each batch sent to the proxy service for an external function.
REQUEST_TRANSLATOR [1]VARCHARName of the external function’s request translator (if any).
RESPONSE_TRANSLATOR [1]VARCHARName of the external function’s response translator (if any).
COMPRESSION [1]VARCHARType of compression used for serializing function payload.
IMPORTSVARCHARNames of files (including their stage location and path) containing imported libraries.
HANDLERVARCHARName of the handler function or class.
TARGET_PATHVARCHARPath to the stage in which Snowflake stores the compiled result of inline handler code.
RUNTIME_VERSIONVARCHARRuntime version of the function’s handler language; NULL if the function handler is written in SQL or JavaScript.
PACKAGESVARCHARNames of packages specified in the PACKAGES clause of the CREATE FUNCTION statement. Currently, this column applies only when the handler is written in Python, Java, or Scala.
INSTALLED_PACKAGESVARCHARNames of all packages installed by the function. This includes packages specified by the PACKAGES clause as well as their installed dependencies. Currently, this column applies only when the handler is written in Python.
IS_MEMOIZABLEVARCHAR(3)YES if the function is memoizable; otherwise, NO.
EXTERNAL_ACCESS_INTEGRATIONSVARCHARNames of external access integrations specified by the function’s EXTERNAL_ACCESS_INTEGRATIONS parameter.
SECRETSVARCHARMap of secrets specified by the function’s SECRETS parameter, where map keys are secret variable names and map values are secret object names.
IS_DATA_METRICVARCHAR(3)YES if the function is a data metric function; otherwise, NO.
IS_AGGREGATEVARCHAR(3)YES if the function is an aggregate function; otherwise, NO.
ARTIFACT_REPOSITORYVARCHARName of the artifact repository used to resolve packages for the function.

Usage notes

  • The view only displays objects for which the current role for the session has been granted access privileges. The view does not honor the MANAGE GRANTS privilege and consequently might show less information compared to a SHOW command when both are executed by a user who holds the MANAGE GRANTS privilege.
  • Omitting a length for the VARCHAR type results in a VARCHAR that specifies the default maximum length. For more information, see VARCHAR.
  • The LAST_ALTERED column is updated when the following operations are performed on an object:

    • DDL operations.
    • DML operations (for tables only). This column is updated even when no rows are affected by the DML statement.
    • Background maintenance operations on metadata performed by Snowflake.