FairCom Corporation


F.7 AllocateBatch


Optionally allocates buffer space for multiple batches (groups of records).

SHORT NAME

ALCBAT

TYPE

ISAM function

DECLARATION

COUNT AllocateBatch(COUNT numbat)

DESCRIPTION

AllocateBatch an optional part of the API called internally by ChangeBatch.

AllocateBatch allocates data structures for multiple, simultaneous batches. Ordinarily the c-tree Plus batch function, DoBatch, is used for only one batch at a time. Each time ChangeBatch is called with a previously unused numbat, a new batch structure is allocated and maintained by c-tree Plus. Therefore, calling AllocateBatch is optional, as it is automatically called by ChangeBatch.

Prior to c-tree Plus V6.4B, the numbat parameter was a unique batch identification number. numbat is ignored by c-tree Plus V6.4B and after. See ChangeBatch for more information.

RETURN

Value
Symbolic Constant
Explanation
0
NO_ERROR
Successful allocation.
184
ISDP_ERR
AllocateBatch already called for this batch. Call FreeBatch if you must recall AllocateBatch.
185
ISAL_ERR
No memory available for set buffers.

See Appendix A "c-tree Plus Error Codes" of the c-tree Plus Programmer's Reference Guide for a complete listing of valid c-tree Plus error values.

EXAMPLE

See the ChangeBatch example.

SEE ALSO

ChangeBatch, FreeBatch, and DoBatch.


FairCom Corporation
www.faircom.com