Mission Base

Program Base Library Functions

int pblIsamInsert

( pblIsamFile_t* isamfile, void* allkeys,
  size_t allkeyslen, void* data,
  size_t datalen )

insert a new record with the given keys and data into the isam file,

Documentation

insert a new record with the given keys and data into the isam file,

the current record of the file will be set to the new record

RESTRICTIONS:
- the file must be open for update,
- allkeys must point to the keys to be inserted,
- allkeyslen must be bigger than 0 and smaller than 1024,
- data must point to the data be inserted,
- datalen must not be negative,
- if datalen == 0, the pointer data is not evaluated at all

Parameter allkeys must contain all values for all keys of the record. The values have to be prepended by one byte giving the length of the following value. All values have to be concatenated into one string.

Example:

 4isam4file3key 
with the numbers as binary values and the letters ASCII, specifies three keys with the values "isam", "file" and "key".

Parameters:
isamfile - ISAM file to insert to
allkeys - pointers to all keys to insert
allkeyslen - total length of all keys to insert
data - data to insert
datalen - length of the data
Returns:
int rc == 0: call went OK
int rc != 0: some error occurred, see pbl_errno

Alphabetic index



This page was generated with the help of DOC++.