gtpc2m1cC/C++ Language Support User's Guide

dbsac-Attach TPF Application Requester Database Support Structure

This function is used to attach the TPFAR Structured Query Language Transaction Profile (STP) and associated blocks to the existing ECB. This TPFAR database support structure must have been detached from this or another ECB using the dbsdc.h function.

Format

#include   <tpfarapi.h>
enum DBSAC_RETURN_CODE dbsac(char *id);

id
A pointer to an 8-byte area that contains the TPF Application Requester (TPFAR) database support structure identifier. This 8-byte identifier must have been previously supplied by the dbsdc.h function.

Normal Return

DBSAC_SUCCESSFUL
Completed successfully.

Error Return

DBSAC_INUSE
A TPFAR database support structure is already attached to the current ECB.

DBSAC_DBSFINDERR
Cannot find the TPFAR database support structure.

DBSAC_CCAFINDERR
Cannot find a file record associated with a cursor control area (CCA) entry.

Programming Considerations

Examples

The following example reattaches a previously detached TPFAR database support structure.

#include <tpfarapi.h>
char id[8]

  ·
  ·
  ·
dbsac(id);

Related Information