Fixed Length Importer

Introduction

A fixed length file is made up of elements that have a fixed length throughout the file. Dispite having a long history in computing, they remain a popular format.

A Fixed Length Importer is used to read in a fixed length file into paygate ready for payment processing.

In creating an importer we not only read the file, we also give the file meaning and context. For example we attempt to define in an importer, that a certain field is a sortcode, an amount or a transaction code. We make use of this contextualisation throughout paygate with features such as rules, and auto-mapping.

Creating a Fixed Length Importer

Title

Give the importer a meaningful title that makes the purpose or use of the importer obvious. For example ‘Oracle payment file’ would be a good example of a tile.

Description

The description is an optional field that you can use to describe the importer in more detail.

File Location

An optional field to set the default file location of the imported file. This can be modified as the importer is used and so can be left blank if you don’t know it or if the location or filename will change over time.

Data Type

Select the type of data that the imported file will contain.


File Cleaner

Often a payment file will contain hidden control characters that cause import problems. Or sometimes, if the file originates on a unix system or mainframe. the row delimiters may cause import problems.

Another common problem is that a file uses an incorrect character that is incompatible with, for example, BACS. Incompatible characters can payments to fail and so need to be dealt with.

This common problems can easily be dealt with by using the File Cleaning capailities that are built into paygate importers.

Cleaner Rules

Cleaner Rules are a set of common rules that, when selected, modify the incoming file befofree it is imported into paygate. They are designed to make importing easier by normalising the files ready for importing.

Importer

Convert to Upper Case - Converts all lower case characters to upper case.

Remove ASCII Nulls - This rule strips ASCII Nulls (ASCII Code 0) from the file.

Convert LF to CRLF - Files that use LF to terminate individual rows have the LF replace with CRLF

Convert CR to CRLF - Files that use CR to terminate individual rows have the LF replace with CRLF

Convert CRLF to CR - Files that use CRLF to terminate individual rows have the LF replace with CR

Convert CRLF to LF - Files that use CRLF to terminate individual rows have the LF replace with LF

Convert CR to LF - Files that use CR to terminate individual rows have the LF replace with LF

Convert LF to CR - Files that use LF to terminate individual rows have the LF replace with CR

Convert To UTF-8 - Converts the entire file to UTF-8 format

Character Set

When File Cleaning is enabled, the importer will inspect the characters in the file and substitute any characters that are not in the selected character set, to a whitespace. For example, if the BACS character set is selected then all non-BACS characters are replaced with a whitespace. This is a good way to ensure that the imported file only contains legal characters without causing the format or structure of the file to be altered.

Substitution

Substitution replaces single characters , in an imported file, with a substitute character. Your can create multiple rules in an importer that substitute 1 or more characters.

Importer

Click ‘Add Rule’. Enter the single character that you wish to replace in the ‘From’ box. Enter the substitute character in the ‘To’ box. Click ‘Add Rule’ again to add more substitution rules.

Remove an existing rule by clicking the red ‘trashcan’ icon.

You can enable or disable individual rules using the check boxes in the ‘Enabled’ column.


File Pre-Processing

File Pre-Processing modifies a file before it is imported by paygate. It consists of a set or predefined rules that can be chained together to build complex reformating rules.

You use pre-processing when you have a file that just can’t be imported using the standard importer tools.

Examples of where you might use pre-processing:

For more details, see the section File Pre-Processing


Columns

The columns section of the importer pages is where you tell the importer about the structure of the fixed length file.

In a fixed length file


Cleaning, Pre-processing, Importing order

Importer

The image above shows the order in which cleaning, pre-processing and importign takes place:


Cloning an Importer

You can make a clone of the importer by clicking the Clone button at the foot of the page. Cloning an importer creates a new importer with the same configuration as the donor importer. The new cloned importer is now independent of the donor importer and configuration changes can be made without affecting the donor. Both the donor and clone importer now have separate logging records and can be used in different mappings.


Other Internal Rules

During import the fixed length importer will attempt to detect and correct data that may cause problems when storing the data. The following rules are followed

Amount

Any amount that cannot be expressed as a valid decimal number will be converted to a zero (0) amount.