Using the Bulk Import and Export Utilities
Page 9 of 12

Default Input or Output File Format

When no control file is specified, the input or output file takes on the default file format.

The default file format is a delimited ASCII file with the following characteristics:

  • Rows are separated by a new line.
  • Fields are separated by a comma (,).
  • Field start is indicated by a double quote (").
  • Field end is indicated by a double quote (").
  • Field start and end are optional unless the field itself contains a field separator (comma) or row separator (CR-LF). For example, if a field contains the string "Hey, look over here!" the field start and end must be indicated by double quotation marks.

An example file of four rows and four columns using default file format:

1,abc,22,def
22,,,"a is a zero-length string, b is null"
13,hello,454,"world  "
4,b and c are both null,,

With no control file specified, this is what COM.cloudscape.tools.FileExport outputs:

"1","abc","22","def"
"22",,,"a is a zero-length string, b is null"
"13","hello","454","world  "
"4","b and c are both null",,

To create a file in any other format, use Cloudview to create a control file that specifies the format. To create a control file, choose Edit->Export from the Cloudview menu, then choose Save on the Advanced tab.

Use a control file to specify the following:

  • Fixed-width instead of delimited file. You will need to specify the width of each field.
  • Field separator characters.
  • Field start and end characters.
  • Row separators.
  • If you are using a fixed-width file, the default output value for NULLs.