gtpc2m1c | C/C++ Language Support User's Guide |
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
- A system error with return results if an incorrect TPFAR database support
structure identifier is specified.
- Once the TPFAR database support structure is reattached to the ECB, the
TPFAR database support structure identifier is no longer valid and must not be
reused.
Examples
The following example reattaches a previously detached TPFAR database
support structure.
#include <tpfarapi.h>
char id[8]
·
·
·
dbsac(id);
Related Information