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

Using mi_xa_register_xadatasource( )

3

The mi_xa_register_xadatasource( ) function 3registers an XA data source with the current transaction. This function 3must be repeated with each new transaction. This function operates 3the same way as the ax_reg( ) function.

3

Use the following syntax for an mi_xa_register_xadatasource( ) function:

3
mi_integer mi_xa_register_xadatasource(mi_string *xasrc)
3

For example: 3

3
     #include "xa.h"
3     #include "milib.h"
3     int    retcode;
3   retcode = mi_xa_register_xadatasource("informix.Newyork"));
3  if ( retcode != MI_OK)
3       {
3        /* Error while registering the XA data source   */
3       }
3            /* Success fully registered */
3

When you use the mi_xa_register_xadatasource( ) function, 3follow these guidelines: 3

3 3

Multiple registrations of the same XA data source in a single 3transaction do not effect either the transaction or the XA data 3source.

3

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

Enterprise Edition Home | Express Edition Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]