Home | Previous Page | Next Page   Database Access > Working with XA-Compliant External Data Sources > Registering and Unregistering XA-Compliant Data Sources > 3 3 3

Getting the Resource Manager ID

3

When 3specifying how user-defined routines register and unregister a data 3source using the ax_reg( ) or ax_unreg( ) function, 3you can use the mi_xa_get_xadatasource_rmid( ) function 3to get the resource manager ID that was previously created in the 3database for an XA-compliant, external data source. The mi_xa_get_xadatasource_rmid( ) function 3can be used while invoking the ax_reg( ) or the ax_unreg( ) function 3in subsequent calls.

3

The syntax for the function is: 3

3
mi_integer mi_xa_get_xadatasource_rmid(mi_string *xasrc)
3

xasrc is the user-defined name of the 3XA data source.

3

For example: 3

3
     #include "xa.h"
3     #include "milib.h"
3     int   rmid;
3   rmid = mi_xa_get_xadatasource_rmid("informix.Newyork");
3  if (rmid  <= 0)
3       {
3        /* Error while getting XA data source id */
3       }
3/* Successful */
3

For more information on this function, see the IBM Informix: DataBlade API Function Reference.

Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]