next up previous contents
Next: CIFLIB Schema Construction Functions Up: CIFLIB File Access Functions Previous: cifWriteFile

cifWriteDataBlock

NAME cifWriteDataBlock

PROTOTYPE

#include "ciflib.h"

int  cifWriteDataBlock(const char *outputFileName,
                       const char  mode, 
                       const char *dataBlockName, 
                       const int   templateFlag, 
                       const int   esdFlag,
                       const char *dictionaryName, 
                       const char *version)
PURPOSE

cifWriteDataBlock writes the named data block to the named output file. The mode flag determines if the write operation either overwrites or appends the output file. Setting the templateFlag causes the descriptions and examples of each data item to be inserted into the output file as comments. This option can be used to create the CIF template files that are used by the NDB project. Setting the esdFlag to zero causes precision estimates to be appended to data items that have the DDL attribute _item_conditions.code of esd; otherwise, the precision estimates are included in the appropriate data items. The choice of possible alias translations is controlled by specifying the name and version of the dictionary in which the desired names are defined.

RECEIVES

dataBlockName name of the source data block
outputFileName path name of the output file
mode output mode; 'w' overwrites and 'a' appends.
templateFlag a non-zero value requests output in template format
esdFlag a zero value requests appended esd's
dictionaryName name of the dictionary for alias translation
version dictionary version for alias translation

RETURN VALUE

Returns 1 for success or 0 for failure.

REMARKS

See also: cifSaveFile
  cifReadFile
  cifCloseFile
  cifWriteFile


next up previous contents
Next: CIFLIB Schema Construction Functions Up: CIFLIB File Access Functions Previous: cifWriteFile
Olivera Tosic
6/17/2002