MySQL 8.0.39
Source Code Documentation
s_mysql_udf_registration Struct Reference

Service for adding and removing UDF functions. More...

#include <udf_registration.h>

Public Attributes

mysql_service_status_t(* udf_register )(const char *func_name, enum Item_result return_type, Udf_func_any func, Udf_func_init init_func, Udf_func_deinit deinit_func)
 Registers a UDF function with a given name. More...
 
mysql_service_status_t(* udf_unregister )(const char *name, int *was_present)
 Unregisters a UDF function with a given name. More...
 

Detailed Description

Service for adding and removing UDF functions.

Member Data Documentation

◆ udf_register

mysql_service_status_t(* s_mysql_udf_registration::udf_register) (const char *func_name, enum Item_result return_type, Udf_func_any func, Udf_func_init init_func, Udf_func_deinit deinit_func)

Registers a UDF function with a given name.

The name must be unique. Does not store in any table, just updates the global function list. Plugins/components need to handle registration deregistration during their initialization and deinitialization. Registers a scalar UDF by default.

See also
udf_aggregates
Parameters
namename of the function
return_typereturn type.
funcfunction to call
init_funcfunction to call at query start
deinit_funcfunction to call at query cleanup
Returns
Status of performed operation
Return values
falsesuccess
truefailure

◆ udf_unregister

mysql_service_status_t(* s_mysql_udf_registration::udf_unregister) (const char *name, int *was_present)

Unregisters a UDF function with a given name.

Does not store in any table, just updates the global function list. Plugins/components need to handle registration deregistration during their initialization and deinitialization.

Parameters
namename of the function
[out]was_presentset to non-zero if the UDF was present, but locked
Returns
Status of performed operation
Return values
falsesuccess
truefailure

The documentation for this struct was generated from the following file: