|
The mi_fp_setfuncstate() accessor function sets the user-state pointer for the user-defined routine in its associated MI_FPARAM structure.
fparam_ptr | is the pointer to the associated MI_FPARAM structure. |
state_ptr | is a pointer to the user-state information that is stored as the user-state pointer. |
The mi_fp_setfuncstate() function sets the user-state pointer for the user-defined routine that is associated with the fparam_ptr MI_FPARAM structure. The user-state pointer points to a user-defined buffer or structure that contains private state information for the user-defined routine. In the first invocation of the UDR, the database server sets the user-state pointer to NULL. Use the mi_fp_funcstate() function to return the user-state pointer so that you can access the private state information within a UDR.
Cast the state_ptr pointer to "void *" before you store it as the user-state pointer. For example, the following call to mi_fp_setfuncstate() casts a pointer to a structure called udr_info before it stores it as the user-state pointer in an MI_FPARAM structure:
None.
See the descriptions of the following functions: mi_fp_funcstate(), mi_fp_setargisnull(), mi_fp_setarglen(), mi_fp_setargprec(), mi_fp_setargscale(), mi_fp_setargtype(), mi_fp_setretlen(), mi_fp_setretprec(), mi_fp_setretscale(), mi_fp_setrettype(), and mi_fp_setreturnisnull().