ddlLoadMem()/ddlLoadMemEx() - load records from a memory array
ddlLoadMem()/ddlLoadMemEx() - load records from a memory array
Prototype:
void ddlLoadMem(
CONTROL *ctl,
char *OptionString,
char *ArgString,
char *DataArray,
int DataItemSize,
long DataItemCount);
void ddlLoadMemEx(
CONTROL *ctl,
char *OptionString,
char *ArgString,
char *DataArray,
int DataItemSize,
long DataItemCount,
long *RecNoRef);
Permitted values in OptionString:
|
/B - data in InputFile is blocked in fixed length records with no CRLF;
this is the default for ddlLoadMem();
/Cn - load the first n records only;
/F - blank fill ascii fields that contain the null character;
|
Form of ArgList:
[<cx>] <TableName>
<RDname> [<DummyFileName>]
Description of Parameter DataItemSize:
|
int DataItemSize is the size (in bytes) of each data item.
DataItemSize must be equal to the length of the record specified by RDname.
|
Description of Parameter DataItemCount:
|
long DataItemCount is the number of data items in DataArray.
|
Description of Parameter RecNoRef [ddlLoadMemEx() only]:
|
long *RecNoRef is the pointer to an array of at least DataItemCount long integers.
As each record is loaded, its 1-relative record number is stored into the next
successive member of this array.
This parameter may also be NULL [i.e., (long*)0]; in this case, no record number values are stored.
|
Description:
Loads the record images from DataArray to the specified table.
The <cx> argument is not required. In general, it is more efficient to
omit it, especially for very large record counts. It is useful primarily to operate
on the loaded data after the ddlLoadMem() function is complete.
Values returned in Control Structure:
Control.Ans1 |
Number of records loaded |
Control.Ans3 |
Number of records loaded with errors |