Rules for Exporting from a Table to a Text File

When you export the table to a text file, Monarch Classic uses the following rules to create the export file:

Records (lines)

The active filter, if any, determines which records will be exported. Only those records that satisfy the filter are exported. This creates an export file that matches the records you see on screen in the Table window.

Fields (columns)

Hidden fields are excluded from the export file. All other fields, including calculated fields are exported.

Each memo field is exported as a block of text, preceded and terminated with a CR/LF/TAB/CR/LF sequence to separate it from other fields. The non-visible TAB characters are included as a delimiter to indicate the beginning and end of each memo text block.

Field names

Monarch Classic can optionally export the field names as the first line of text. To export the field names, select the Include field names as the first row of output setting. For a description of this option, refer to the Field Names tab of Export Options.

Field data

The data exported from each field is determined by its column width setting. If a column width is too short to accommodate a field value, that value is truncated. If a column width is wider than a field value, that value is padded with spaces. This results in a text file that reflects the data and column spacing you see on screen.

Numeric fields may optionally be formatted with leading and trailing zeros (in a format similar to that used by older COBOL applications. See the Pad numeric fields with zeros, suppress the decimal point, and use trailing negation setting in the Text Files tab of Export Options.

For memo fields, the entire memo field is exported, even though only the first row is visible in the Table window.

 

 

© 2024 Altair Engineering Inc. All Rights Reserved.

Intellectual Property Rights Notice | Technical Support