Description

The FixedFileReceiver writes Domain Attribute values in a fixed format to a file.  Column Name and fixed length are defined through Receiver Attribute Property keys. 


Parameters

The following parameters can be defined for the FixedFileReceiver. Items with an asterisk (*) are required: 

  • outputPath* - Defines the location to store the newly generated fixed output file.
  • subDir - Defines the sub-directory location to store the newly generated output file.
  • outputFileName* - Defines the name of the output file.
  • lineSeparator - Defines a line separator, which will be appended at the end of each line. 
  • delimiter - Defines the character used as the column delimiter.
  • quoteTextData* - Defines the character to use when quoting text data.
  • includeHeader* - Defines whether to include the header in the Fixed File or not.


Line Separator

This Receiver allows a line separator to be used within the fixed file. Here are some examples: 

  • \n
  • \r
  • \r\n


Delimiter

This Receiver allows for a delimiter to be placed at the end of each column in a record. Here are some examples: 

  • Tab - \t
  • Pipe - |
  • Comma - ,  


QuoteTextData

This Receiver allows for three quoteTextData types:

  • None - text
  • Single - 'text'
  • Double - "text"


Receiver Attribute Property Keys

The Receiver defines three property keys that can be modified on any of its associated Domain Attributes:

  • columnName - Defines the column name as it will be output in the delimited file header.
  • include - Determines if the Attribute will be included as a column in the output.
  • length - Defines the fixed length for each Attribute.


Example Domain

The example output is based on following Domain defined below: 



Example 1: Fixed File Format Output with Header and Line Separator

For this example, the file has been named "user" and includes headers with a line separator \n. The headers will appear at the top of the file and the line separator ensures that each record will appear on its own line in the output file. 



The length has been defined for each Attribute, as shown below: 



Sample Output

The following is an example output of User Domain generated data and fixed file formatted output from the FixedFileReceiver configuration shown above: