Chapter 2

File templates

A file template describes the layout of a file you work with: what kind of file it is, how its fields are separated, whether it has a header row, and which columns it carries. Mappings, transforms and validation all read files through a template.

The File Templates list

Open File Templates from the Transform group. The list shows every template you have saved and how many of your 10 you have used. The command bar offers:

A template with no columns is flagged in the list, because nothing can be mapped or validated from it.

Creating a template

  1. Click New.
  2. Enter a Template name. This is the name you will pick from in the transform wizard, validation and the mapping editor.
  3. Choose a File type: CSV, TSV or Excel (.xlsx). Excel templates read the first worksheet.
  4. Optionally add a Description, for example which system produces the file and who receives it.
  5. Under Reading, set the Delimiter, the character between fields (use \t for a tab). It is ignored for Excel.
  6. Tick The file has a header row if the first line holds column names. When it does, the file's header names are matched to your columns by name rather than by position. Untick it for files that start straight into data.
  7. Add the columns (below), then click Save.

Columns

Click Add column for each column in the file, in order. For each one set:

FieldWhat it means
NameThe column's name in the file. Rows without a name are highlighted until you fill one in.
TypeString, Integer, Decimal, Date or Boolean. Validation checks each value against it.
RequiredTick it if every row must have a value in this column. Validation reports empty required values.

Use the arrows to move a column up or down, and the bin icon to remove it. Remove All in the command bar clears every column.

TipA template without columns can still pass a file through unchanged, but nothing can be validated, renamed or converted. Add at least the columns you care about.
NoteFixed-width files are no longer supported. A template saved as fixed width by an older build opens as CSV with a notice; check the delimiter before saving it again.

The 10-template limit

The free edition stores up to 10 templates. When you have 10, saving another is refused with the message "You have reached the limit of 10 file templates." Delete a template you no longer use, or export your work first (chapter 6) and keep the file as an archive. Any paid module removes the limit Full edition.

Next

With templates for your incoming and outgoing layouts, build a field mapping between them, or check a file against a template with Validate File.