Separate the MT940 bank reference from a truncated customer reference
In :61: the customer reference follows the transaction type and the optional bank reference follows //. The customer slot can truncate a long ERP key, so use additional remittance evidence before clearing a match.
Open this sample in Air-Gapped ConverterWorked bank sample
Synthetic bank data for local reconciliation.
:20:REPORT-1
:25:EUR-OPERATING
:28C:007/1
:60F:C261130EUR100,00
:61:261130C25,00NTRFINV-2026-0000042//BANK-00841
:86:EREF+INV-2026-00000427-A
:62F:C261130EUR125,00Field anatomy
| Field or path | Meaning in this file | Type or format | ERP or Excel import risk |
|---|---|---|---|
| After NTRF | Customer reference | Up to 16 characters | A shortened prefix can match several invoices. |
| After // | Bank reference | Up to 16 characters | Concatenation hides the independent bank lookup key. |
Root cause and ERP fix
- Two invoice IDs share a prefix. Recover the full EREF from :86: and confirm the amount.
- A missing bank reference shifted the customer value. Keep an empty bank field when // is absent.
- An import treated NONREF as unique. Exclude placeholders from automatic matching.
Inspect with the MIT parser
Save the sample as mt940-bank-and-customer-references.sta and the script as inspect.mjs. With @stmtrecon/parser installed, run node inspect.mjs mt940-bank-and-customer-references.sta.
import { readFile } from 'node:fs/promises';
import { inspect } from '@stmtrecon/parser';
const text = await readFile(process.argv[2], 'utf8');
const report = inspect(text, { transactions: true });
const lines = text.split(/\r?\n/).filter(line => line.startsWith(':61:'));
const refs = lines[0].match(/NTRF([^/]*)(?:\/\/(.*))?$/);
console.log(refs[1], refs[2], report.transactions[0].narrative);Open this sample in Air-Gapped ConverterExport a multi-sheet Excel workbook with balance checks and batch reconciliation on your device. No Node installation or cloud upload is required.
npm package · SDK source · Format reference