Modify Flat Records

When working on EC flat files, there are instances when modifications are required before doing any EC process. You can perform these modifications:

  • Removing header records

  • Removing other unwanted records

  • Changing record separator

  • Removing "garbage" characters

  • Replacing non-XML characters

Typically these modifications must be completed before the Split Redetect process or before the FLAT to XML process.

When a flat file reaches the FLAT to XML process the flat file should conform to the message specification and nothing else. All extra records, wrong record separators, "garbage" characters, and others that are created by different communication processes from the trading partner. Otherwise, these must be removed or fixed prior to converting flat file to XML.

Modifying Flat Record is a generic process that uses regular expressions. A basic to good knowledge of regular expressions is recommended to fully benefit from this process.

Split Redetect Process

Split Redetect is a process that splits a message based on the header, trailer, and regular expression settings, and then sends the split messages back to EC for redetection.

Modify Flat Record Process

The process Modify Flat Record has two properties and one or more Strip/Replacement steps that need to be configured. The properties Record Separator and Max Record Length define the records. The Strip/Replacement steps define what to do with the records, that is to strip (remove) them or to modify them in some way.

For more information, see Javadoc for the class Pattern:

http://java.sun.com/j2se/1.5/docs/api/java/util/regex/Pattern.html