Setup > A/P-A/R accounting > Files > Bank file definitions 

Use this function define the bank file formats used when creating remittances manually or in a batch process.

This table describes the created bank file formats:

  • Targeting banks
  • By the banks or the factors

The format (either fixed or variable) can be customized for each bank, but it must be modified with caution. In particular, you can modify these formats when some banks demand specific information and/or a different order in the transmitted data. A bank file is identified by a code, which code is specified by the payment transactions setup, and by an optional bank code.

When an interface bank file is created for a particular bank, the system checks if there is a setup for the correct code and the corresponding bank. If there is none, the default setup defined for the empty bank code is used.

The following standard formats are available to manage standard payment modes, in compliance with the French Committee for Banking Organization and Standards (CFONB). All the formats are delivered with an empty bank code, but you can copy these records by specifying a particular bank code and create new formats with other codes.

Code

Title

LCR (electronic bill of exchange)

LCR deposit

PRELEVE

BP debit

VIREMENT

Bank transfer

VIRINTER

International bank transfer

The following formats are also available in standard for managing bank files not related to bank payments, to be integrated or extracted:

Code

Title

RELBAN

Bank statement to be integrated

RELLCRBOR

Paying bank files of the bank to integrate

REPLCRBOR

Answer to the LCR or BOR statement (to be extracted)

QUITTANCE

Factoring receipt for the factor

 

Prerequisites

SEEREFERTTO Refer to documentation Implementation

Screen management

Entry screen

Presentation

Each file format defines the records.
It usually includes header, detail, sub-total and total records, but there are also some specific cases:

  • For those files defining the factoring receipts, two additional levels exist called sub-total and detail 2.
  • For bank statements, an additional level is provided.
  • In some cases, (i.e., international transfers), there can be two detail levels identified by an order number that are equal to 1, then 2. The remaining are set to 0 in the other cases.

Close

 

Fields

The following fields are present on this tab :

Block number 1

  • Bank file (field COD)

Enter a unique code for the bank file definition.

This field is optional. It is used to customize the structure of a file for a given bank. The record with the empty bank field will be used for banks with no specific record.

Non-compulsory field containing the legislation code (miscellaneous table 909).

The entered value is used upon creation and validation of the folder and upon addition of data during legislation copy.

The data concerning the requested legislations and the common data (legislation code empty) on folder creation.

Only the records concerning the folder legislations are retrieved on folder validation.

The Legislation field is also used as a filter and checked upon movement selection and entry (entry of invoices, payments, journals etc.).

If the field is empty, the current record can be used whatever the legislation of the company concerned by the movement.

  • Record type (field RECTYP)

Select the record type:

  • Header
  • Detail
  • Total
  • Subtotal
  • Detail 2

  • Detail order number (field ORDNUM)

This order number is used to break down and sort the 'Detail' type records.

Block number 5

  • Description (field DESTRA)

 

  • Short description (field SHOTRA)

 

  • File prefix (field FILREF)

This sequence will be used as a prefix in the names of the files generated by this descriptor.

  • Format type (field FMT)

Select the format type:

Fixed

This format is used to exchange fixed-format files with the bank, such as bank statements and bills of exchange.

The data file generated is based on the formula entered in the Formula field. The position and length of data are set in this file.

Variable

This format is used to exchange XML files with the bank, such as SEPA and non SEPA transfers and direct debit.

The data file generated is based on the formula entered in the Formula field. The data displays in tags that are entered in the Start separator and End separator fields. Selecting this format displays the Mandatory and Condition columns required in the setup.

For bank files subject to the SEPA standard (Variable type and bank file group SEPA bank transfer (SCT) or SEPA direct debit (SDD), only the following characters are authorized:
a b c d e f g h i j k l m n o p q r s t u v w x y z
A B C D E F G H I J K L M O P Q R S T U V W X Y Z
0 1 2 3 4 5 6 7 8 9
- ? : (  ) . , "  and / (only inside a zone)
Space character
A control on characters is performed when generating the file.
- If a prohibited character is included in a chain of characters, it is automatically replaced with a blank space.
- If a prohibited character is placed at the start or end of a chain, it is automatically deleted.
For example :
          <Nm>/COMPANY FATHER&SONS/</Nm>
After a new processing in Sage X3:
          <Nm>COMPANY FATHER SONS</Nm> (deletion of start and end '/' characters in the tag and '&' character replaced by a blank space).

The Length, Formula and Title columns are common to both format types.

CSV

This format type generates a comma-separated values file. When you select this format, you can enter a Field separator and a Field delimiter. When the output file is generated through the bank file generation process, these are automatically applied to the fields defined as records. You can also use Header and Footer and Detail line definition as needed.

You no longer need to manually define field separators as part of the Fixed length type definition.

In the Records section, enter the definitions of each field of the CSV file. Each line in the grid represents one field.

Populate the following columns of the grid:

  • Field type: controls the data type of the field
  • Formula: defines the content of the field (=data). Same options as for other formats (i.e. reference to a database field, functions, fixed texts) are supported.
  • Description: optional

Additional notes:

As the last record, you must enter the end of line delimiter character as a binary field (see example). End of line characters are not added automatically.

If a field separator character is part of an alphanumeric field, like a BP name or remittance information, it is removed when the file is generated to ensure file structure integrity.

Only one header and/or one footer record can be defined. If the header or footer contains several lines, you can define the entire structure within the file.

For technical reasons it is mandatory to always create a header record for the bank file definition even if no header lines are needed. In this case you need to create a dummy record. For example:

At the header record, in the Condition field, you can enter [F:TFB]BAN = 'DUMMY' or simply 1=2 and at least a single-record line (i.e., as an empty text field). The latter condition always equals FALSE and suppresses generating the record.

CSV bank file definition example:

Field type

Formula

Description

Alphanumeric

"Batch description"

 

Alphanumeric

func NEDBANKLIB.BATCHDATE_AND_INT_SUM(datetime$)

 

Alphanumeric

[F:BAN]SENNUM

 

Binary

chr$(13)+chr$(10)

 

This definition creates the following CSV output, assuming a semicolon ; was entered as field separator:

Batch description;20201051200;234AB3222XYZ945;<CR><LF>

Line 1 = first field: fixed text "Batch description"

Line 2 = second field: using a function to generate the required date and specific format

Line 3 = third field: this field in the file is populated directly from a database field with the value 234AB3222XYZ945

Line 4 = end of line character as binary representation (here: carriage return+line feed)

  • Field separator (field FLDSEP)

For CSV format types only, you must define a character to separate fields. Commas or semicolons are typical.

  • Field delimiter (field FLDDEL)

For CSV format types only, enter a character to mark alphanumeric files. Quotes or single quotes are typical.

  • Character coding (field FILFMT)

For CSV format types only, select the character encoding to apply to the file:

  • ASCII
  • UTF-8
  • UCS-2

  • File extension (field FILEXO)

Enter the extension of the file names that will be generated for the magnetic transfers. They can contain up to four characters.

  • Condition (field FORCND)

Enter a formula conditioning the entry of the current record.

This field is specified at the detail order number level.

For CSV format types, use this field to fine a dummy header file when you don’t have an actual header. You can enter [F:TFB]BAN = 'DUMMY' or simply 1=2 and at least a single-record line. The latter condition always equals FALSE and suppresses generating the record.

Grid Records

  • No. (field NUM)

Invoice number.
This number is used to identify the invoice in a unique way. It is entered upon each creation or automatically generated depending on the counter associated with the invoice type.

  • Field type (field FLDTYP)

No help linked to this field.

  • Position (field POS)

 

  • Length (field LNG)

No help linked to this field.

  • Start separator (field STRSEP)

Enter the start separator. A control is performed between the start and end tags to make sure that the tags are consistent with each other.

You can add an attribute in the XML tag:

  • In the tag, use the code $1$ as a value.
  • In the XML file, this code $1$ is then replaced by the result of the formula entered in the Formula field.

For example:

  • The start separator is <InstdAmt Ccy="$1$">.
  • The formula in the field Formula is [F:PYH]CUR.
  • In the generated XML file, $1$ is then replaced by the currency. For instance: <InstdAmt Ccy= "EUR">1000</InstdAmt>


If the start separator contains the code $1$, the first occurrence of $1$ is replaced by the result of the evaluated formula. The other occurrences of $1$ are not modified.

If the start separator does not contain that $1$ code, the result of the formula is displayed in the XML file after the tag.

  • Formula (field FRM)

For Variable bank file types, you can define the variables used in the XML file.

Examples:

[L]MSGID This variable contains the value of the sequence number used. This sequence number is defined in the Sequence number assignment function.

[L]NBPYH This variable contains the number of payments included in the file.

[L]TOTCUR This variable contains the sum of all the payments included in the file without taking currencies or conversion into account.

  • Mandatory (field OBY)

This column only displays for Variable bank file types.

If you have entered a formula, you can mark whether these values are mandatory or not. If you select Yes and you have not enter a formula in theCondition column for generating the XML bank file, you see an error message in the log file when you generate the bank file.

  • End separator (field ENDSEP)

Enter the end separator. A control is performed between the start and end tags to make sure that the tags are consistent with each other. If not, you receive an error message. "The end separator should be </XX>. Do you want to modify it? "

 
  • Condition (field CND)

This field is used to enter a formula conditioning the entry of the current record.

The XML management rules require that the start and end tags are not generated if there is no value between the two tags.

In the event of XML element groups with optional values, this field, if it is not populated, prevents the creation of the record.

Entering a condition is not necessary for the tags with optional values (when the field Mandatory is set to 'No') if these tags are not directly included in an XML element group.

 

  • Description (field DESLIN)

No help linked to this field.

Generation

  • Total length (field TOTLNG)

 

  • Bank file group (field NATPAY)

The payment types makes it possible to associate the bank file with a payment transaction. Several file formats can correspond to the same payment type. Depending on the bank institution or if the payment is national or international, the file format is different.

  • Allow remittance grouping (field FRMGRP)

Select this check box to allow remittances to be grouped when creating the Bank file.

Block number 4

Currency

  • Multicurrency (field CURMULT)

Select this check box to check if the remittance file is in a single currency when multicurrency is forbidden by the file format.

  • Currency control (field CURCTL)

Select the type of currency control:

  • Inactive
  • Authorization
  • Restriction

Table number 2

 

Close

 

Specific Buttons

The following fields are included on the window opened through this button :

Block number 1

  • field OBJET

 

  • field CLES

 

Block number 2

  • From folder (field DOSORG)

Use this field to define the folder from which the record will be copied. The possible syntaxes are described in the Dedicated appendix.

  • All folders (field TOUDOS)

Use this option to copy the record to all the folders defined in the dictionary (ADOSSIER table of the current solution).

  • To folder (field DOSDES)

Use this field to define the folder to which the record will be copied. The possible syntaxes are described in the Dedicated appendix.

Close

This button is used to copy the record definition from or to another folder.

Error messages

In addition to the generic error messages, the following messages can appear during the entry :

Incorrect expression (followed by an additional message)

The syntax of the entered calculation formula is not correct. For example, "A closing bracket is missing."

Tables used

SEEREFERTTO Refer to documentation Implementation