|
The mi_routine_get_by_typeid() function looks up a registered user-defined routine by a routine signature that it builds from a list of arguments and returns its function descriptor.
The mi_routine_get_by_typeid() function creates a function descriptor for the UDR that the routine signature specifies. The function builds the routine signature from the udr_type, udr_name, owner, arg_count, and arg_types arguments. The mi_routine_get_by_typeid() function is one of the functions of the Fastpath interface. It is a constructor function for the function descriptor and
The mi_routine_get_by_typeid() function performs the following tasks:
The mi_routine_get_by_typeid() function allocates a new function descriptor in the PER_COMMAND memory duration.
When the UDR is defined in a database that is not ANSI-compliant, mi_routine_get_by_typeid() looks for UDRs owned only by owner. If you specify a NULL-valued pointer as an owner, mi_routine_get_by_typeid() looks for UDRs owned by anyone. The following call to mi_routine_get_by_typeid() looks for the a_proc() user-defined procedure in a database that is not ANSI compliant:
If a_proc() was defined in an ANSI-compliant database, the following call to mi_routine_get_by_typeid() looks up the a_proc() user-defined procedure owned by user dexter:
Other internal errors raise an exception.
See the descriptions of the following functions: mi_fparam_get(), mi_routine_get(), mi_routine_exec(), mi_routine_end(), and mi_td_cast_get().
For more information, see Calling UDRs with the Fastpath Interface.