Flat file definition metadata

Metadata in a flat file is captured in a flat file definition. Some metadata are mandatory and some are optional. You define mandatory metadata by using a message default or by setting the metadata on the group, record, or field level. For example, the mandatory metadata for a field are: Name, Tag Name, Data Type, and if applicable, Start Position.

For more information, see the topics "Flat File Definition format" and "Changing the Message Component Property Values" in this user guide.

These tables show a list of metadata and description for each component in a flat file definition.

File

This table shows File component metadata.

Metadata Details
ID Identifier for a message transformation definition
Messages Allows only one message per file

Message Definition

This table shows Message Definition component metadata.

Metadata Details
Name Specified for documentation purposes
Tag name Specify a tag identified in XML or a tag written to XML
Escape character Escape sequence for field and record separators
Record separators

Common record separators are:

Carriage return: \r or newline and

Line feed: \n or lf

Fixed length separator If set to true, it defines fixed lengths of records
Field separator fields

Specify a value. There can only be one separator in a message. A record separator is considered as a valid separator.

This value overrides any field length definition.

Ignore preceding field separator Select to ignore preceding field separators
Default alignment Specify the alignment to use when a field does not have a defined alignment. You can use a numeric and alpha field value.
Default padding Specify the padding character to use when a field does not have a defined padding character. You can use numeric and alpha field value.
Default trim

Specify a trim behavior for XML to record if no trim is defined for a field.

Use this to remove a preceding and trailing white space or keep the data unchanged. You can set this for a numeric and alpha field values.

Default empty field value Specify a value to use if the data is empty for a field or tag. If left blanks, empty fields will contain empty tags.

Add first field separator

Specify an extra field separator which is defined on the message level in front of the first field of every record in the message
Add last field separator Specify to add extra file separators after the last field of every record in the message

Records

This table shows Records component metadata.

Metadata Details
Group Specify a sequence of records. Use Groups to create additional structures in the corresponding XML file.
Record Specifies a group of fields in sequence

Group

This table shows Group component metadata.

Metadata Details
Name Used for documentation purposes
Tag name Tag to identify or write
Minimum occurrences Minimum required number of times this group must occur
Maximum occurrences Maximum number of times this group is allowed to occur. Specify a 0 (null) value for unlimited occurrences.

Record

This table shows Record component metadata.

Metadata Details
Maximum occurrences Specify the allowed maximum number of times for this group to occur. Specify a 0 (null) value for unlimited occurrences.
Name Used for documentation purposes
Tag name Select a tag to identify or a tag to write
Minimum occurrences Specify the minimum required number of times this group must occur
Maximum occurrences Specify the maximum number of times this group is allowed to occur. Specify a 0 (null) value for unlimited occurrences.

Field

This table shows Field component metadata.

Metadata Details
Name Used for documentation purposes
Tag name Tag to identify or write
Data type Specify a data type value to differentiate alignment, padding, trimming, and default empty value handling. You can use a numeric and alpha field values. The default value type is alpha.
Padding character Character to pad this field
Alignment Alignment to use for this field
Empty field value Value to use if this field is empty
Trim Indicates whether to trim the field
Identifier Defines whether this field is an identifier
Default value Identifier value that is tested against, or written to.
Start position Field starting position if length-defined fields (no field separator) are defined
Length

If the field length is shorter than this length, the field is padded.

If the length shall be used as parsing fields without a field separator, then the last field can be defined as "-1" , which will allow the field to have a variable length.