Important

Helios features are now enabled during weekly update windows and are no longer directly tied to SingleStore engine releases. Refer to the release notes to view the latest features available in your Helios cluster.

SHOW FUNCTIONS

The SHOW FUNCTIONS command lists any existing user-defined functions in the specified database, including user-defined scalar-valued functions (UDFs) and user-defined table-valued functions (TVFs).

Syntax

SHOW FUNCTIONS [{FROM | IN} database_name] [LIKE pattern]

Remarks

  • The SHOW FUNCTIONS command can be used to list functions in the current database or in another database. The function list returns the name for each function and who is the function definer. To show user-defined aggregate functions (UDAFs), see SHOW AGGREGATES. Use SHOW PROCEDURES to list stored procedures.

  • The Data Format column can be one of: JSON or ROWDAT_1.

  • The Link column shows the Connection Link.

  • When function overloading is enabled, the output of SHOW FUNCTIONS includes columns for a function's arguments and variant ID. For overloaded functions, the columns contain the arguments and variant IDs. For non-overloaded functions, the columns display NULL. Refer to Overloaded Functions and Stored Procedures for more information.

Example - List Functions

The following example lists each function in the current database.

SHOW FUNCTIONS;
+---------------------+-----------------------+---------+-------------+----------------+-----------+
| Functions_in_testDB | Function Type         | Definer | Data Format | Runtime Type   | Link      |
+---------------------+-----------------------+---------+-------------+----------------+-----------+
| tvf_1               | Table Valued Function | root@%  |             | PSQL           |           |
| check_spacingExt    | User Defined Function | root@%  | JSON        | Remote Service | HTTP_link |
+---------------------+-----------------------+---------+-------------+----------------+-----------+

Example - List Overloaded Functions

The following shows the output of SHOW FUNCTIONS with function overloading enabled. The functions in this output are the overloaded print_type functions from Overloaded Functions and Stored Procedures.

SHOW FUNCTIONS;
+-------------------+-----------+-----------------------+------------+---------+-------------+--------------+------+---------+
| Functions_in_test | Arguments | Function Type         | Variant ID | Definer | Data Format | Runtime Type | Link | Options |
+-------------------+-----------+-----------------------+------------+---------+-------------+--------------+------+---------+
| print_type        | BIGINT    | User Defined Function |          1 | root@%  |             | PSQL         |      |         |
| print_type        | INT       | User Defined Function |          0 | root@%  |             | PSQL         |      |         |
+-------------------+-----------+-----------------------+------------+---------+-------------+--------------+------+---------+

Last modified:

Was this article helpful?