SHOW FUNCTION STATUS
Grammar Description
SHOW FUNCTION STATUS is used to display information about all functions in the database, including function names, database names, creation time, etc.
The SHOW FUNCTION STATUS command displays only user-defined functions and does not include system functions. MatrixOne Intelligence supports SQL UDF
Grammar Structure
> SHOW FUNCTION STATUS
[LIKE 'pattern' | WHERE expr]
Syntax Description
LIKE 'pattern' is an optional parameter to filter the function to be displayed. pattern is a pattern string that can be used with % and _ wildcards. For example, to display all functions starting with my_function, you can use the following command:
SHOW FUNCTION STATUS LIKE 'my_function%';
The output result will include information such as function name, database name, type, creation time and modification time.
Example
create function twosum (x float, y float) returns float language sql as 'select $1 + $2' ;
create function helloworld () returns int language sql as 'select id from tbl1 limit 1';
mysql> show function status;
+------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
| Db | Name | Type | Definer | Modified | Created | Security_type | Comment | character_set_client | collation_connection | Database Collation |
+------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
| db1 | twoadd | FUNCTION | admin | 2024-02-22 07:34:30 | 2024-02-22 07:34:30 | DEFINER | | utf8mb4 | utf8mb4_0900_ai_ci | utf8mb4_0900_ai_ci |
| db1 | helloworld | FUNCTION | admin | 2024-02-22 07:34:43 | 2024-02-22 07:34:43 | DEFINER | | utf8mb4 | utf8mb4_0900_ai_ci | utf8mb4_0900_ai_ci |
+------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
2 rows in set (0.10 sec)
mysql> show function status like 'two%';
+------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
| Db | Name | Type | Definer | Modified | Created | Security_type | Comment | character_set_client | collation_connection | Database Collation |
+------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
| db1 | twoadd | FUNCTION | admin | 2024-02-22 07:34:30 | 2024-02-22 07:34:30 | DEFINER | | utf8mb4 | utf8mb4_0900_ai_ci | utf8mb4_0900_ai_ci |
+------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
1 row in set (0.10 sec)